FreeBSD Bugzilla – Attachment 193878 Details for
Bug 193525
Let tip work in hayes mode again
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Improved patch for tip against FreeBSD 10 or newer.
tip.diff (text/plain), 1.31 KB, created by
longwitz
on 2018-05-31 20:16:14 UTC
(
hide
)
Description:
Improved patch for tip against FreeBSD 10 or newer.
Filename:
MIME Type:
Creator:
longwitz
Created:
2018-05-31 20:16:14 UTC
Size:
1.31 KB
patch
obsolete
>--- tip/libacu/hayes.c.orig 2015-03-13 12:07:39.000000000 +0100 >+++ tip/libacu/hayes.c 2015-03-14 12:39:47.000000000 +0100 >@@ -146,10 +146,15 @@ > void > hay_disconnect(void) > { >+ struct termios cntrl; >+ > /* first hang up the modem*/ > #ifdef DEBUG > printf("\rdisconnecting modem....\n\r"); > #endif >+ tcgetattr(FD, &cntrl); >+ cntrl.c_cflag |= CLOCAL; >+ tcsetattr(FD, TCSAFLUSH, &cntrl); > ioctl(FD, TIOCCDTR, 0); > sleep(1); > ioctl(FD, TIOCSDTR, 0); >@@ -195,7 +200,7 @@ > alarm(0); > c &= 0177; > #ifdef DEBUG >- printf("%c 0x%x ", c, c); >+ printf("%c 0x%x\n", c, c); > #endif > for (i = 0; i < strlen(match); i++) > if (c == match[i]) >@@ -252,7 +257,11 @@ > goodbye(void) > { > int len; >+#ifdef DEBUG >+ int rlen; >+#else > char c; >+#endif > > tcflush(FD, TCIOFLUSH); > if (hay_sync()) { >--- tip/tip/tip.c.orig 2015-03-13 12:07:39.000000000 +0100 >+++ tip/tip/tip.c 2015-03-14 12:39:48.000000000 +0100 >@@ -68,9 +68,6 @@ > char *sys = NOSTR, sbuf[12], *p; > int i; > >- /* XXX preserve previous braindamaged behavior */ >- setboolean(value(DC), TRUE); >- > gid = getgid(); > egid = getegid(); > uid = getuid(); >@@ -552,6 +549,8 @@ > cntrl.c_cflag |= CS8; > if (boolean(value(DC))) > cntrl.c_cflag |= CLOCAL; >+ else >+ cntrl.c_cflag &= ~CLOCAL; > if (boolean(value(HARDWAREFLOW))) > cntrl.c_cflag |= CRTSCTS; > cntrl.c_iflag &= ~(ISTRIP|ICRNL);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 193525
: 193878