The mail/metamail port has been patched some time ago to use termios, not sgtty. Unfortunately the patch missed two chunks, which means it still called stty() and gtty(), even though it should have used tcsetattr() and tcgetattr() there. Fix: --- mail/metamail/files/patch-metamail_metamail.c +++ mail/metamail/files/patch-metamail_metamail.c @@ -138,6 +138,33 @@ #else static struct sgttyb MyTtyStateIn, MyTtyStateOut; #endif +@@ -2385,9 +2397,9 @@ + SaveTtyState() { + /* Bogus -- would like a good portable way to reset the terminal state here */ + #if !defined(AMIGA) && !defined(MSDOS) +-#ifdef SYSV +- ioctl(fileno(stdin), TCGETA, &MyTtyStateIn); +- ioctl(fileno(stdout), TCGETA, &MyTtyStateOut); ++#if 1 ++ tcgetattr(fileno(stdin), &MyTtyStateIn); ++ tcgetattr(fileno(stdout), &MyTtyStateOut); + #else + gtty(fileno(stdin), &MyTtyStateIn); + gtty(fileno(stdout), &MyTtyStateOut); +@@ -2398,10 +2410,10 @@ + + RestoreTtyState() { + #if !defined(AMIGA) && !defined(MSDOS) +-#ifdef SYSV ++#if 1 + if (HasSavedTtyState) { +- ioctl(fileno(stdout), TCSETA, &MyTtyStateOut); +- ioctl(fileno(stdin), TCSETA, &MyTtyStateIn); ++ tcsetattr(fileno(stdout), TCSANOW, &MyTtyStateOut); ++ tcsetattr(fileno(stdin), TCSANOW, &MyTtyStateIn); + } + #else + if (HasSavedTtyState) { @@ -2681,15 +2693,15 @@ StartRawStdin() {
Responsible Changed From-To: freebsd-ports-bugs->ed Submitter has GNATS access (via the GNATS Auto Assign Tool)
Maintainer of mail/metamail, Please note that PR ports/124462 has just been submitted. If it contains a patch for an upgrade, an enhancement or a bug fix you agree on, reply to this email stating that you approve the patch and a committer will take care of it. The full text of the PR can be found at: http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/124462 -- Edwin Groothuis via the GNATS Auto Assign Tool edwin@FreeBSD.org
State Changed From-To: open->feedback Awaiting maintainers feedback (via the GNATS Auto Assign Tool)
Sorry, the change seems reasonable enough but the patch seems garbled and won't apply (bad copy / paste ?) Edwin Groothuis writes: > > Maintainer of mail/metamail, > > Please note that PR ports/124462 has just been submitted. > > If it contains a patch for an upgrade, an enhancement or a bug fix > you agree on, reply to this email stating that you approve the patch > and a committer will take care of it. > > The full text of the PR can be found at: > http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/124462 > > -- > Edwin Groothuis via the GNATS Auto Assign Tool > edwin@FreeBSD.org
The patch does apply when obtained through the raw pr page. Approved. jf Jean-Francois Dockes writes: > > Sorry, the change seems reasonable enough but the patch seems > garbled and won't apply (bad copy / paste ?)
State Changed From-To: feedback->open Approved by maintainer
ed 2008-06-19 08:43:39 UTC FreeBSD ports repository (src committer) Modified files: mail/metamail Makefile mail/metamail/files patch-metamail_metamail.c Log: Make metamail compile after the sgtty removal. The metamail port was patched to use termios a long time ago. Unforunately, the patch left some calls to stty() and gtty(). Change these calls to tcgetattr() and tcsetattr(). PR: 124462 Approved by: philip (mentor) Revision Changes Path 1.33 +1 -1 ports/mail/metamail/Makefile 1.4 +27 -0 ports/mail/metamail/files/patch-metamail_metamail.c _______________________________________________ cvs-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/cvs-all To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
State Changed From-To: open->closed Committed. Thanks!