savannah-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Savannah-hackers] Patch to correct setenv(3) bug in screen


From: Michael Schloh von Bennewitz
Subject: [Savannah-hackers] Patch to correct setenv(3) bug in screen
Date: Thu, 27 May 2004 14:59:18 +0200
User-agent: Mutt/1.4.2.1i

Hello,

Please let me know if I'm writing to the wrong folks. I found a bug in
screen-4.0.2, and would like to share my correction by sending a patch. I
wasn't able to find a bug database or better way to report this from the
links on your webpages.

In screen-4.0.2, configure attempts to detect if it is being run on a
Solaris platform. This test fails, because it checks for a 'SVR4' identifier
at buildtime. Compilers on Solaris consistently define '__sun' and '__SVR4'
identifiers, so it's probably best to try to compile a small program using
those. The configure script distributed with screen comes close, but not
close enough (see attached patch).

A more important problem involves a call to 'setenv(3)' on platforms which
the configure script has determined to have a 'setenv(3)' system call
available. Newer versions of Solaris (like Solaris 10) do have setenv(3) and
configure thus detects it. Unfortunately setenv(3) will be called with two
parameters, although the setenv(3) distributed with Solaris 10 specifies
three parameters. My patch fixes this by checking for the presence of
Solaris before calling setenv(3), just as already done when checking for the
presence of Linux.

Our entire patch is also available via CVS, by the way. Check out:

  http://cvs.openpkg.org/rlog?f=openpkg-src/screen/screen.patch

Regards,
Michael, OpenPKG
http://www.openpkg.org/

Attachment: screen.patch
Description: Text document

Attachment: pgpBPn8NTE66g.pgp
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]