develooper Front page | perl.perl5.porters | Postings from July 2001

[PATCH 2/4] -Wall cleanups: mg.c

Thread Next
From:
Richard Soderberg
Date:
July 31, 2001 23:16
Subject:
[PATCH 2/4] -Wall cleanups: mg.c
Message ID:
Pine.LNX.4.21.0107312314120.24343-100000@oregonnet.com
This is the second in a series of patches designed to remove warnings from
the compilation of Perl on FreeBSD-CURRENT, last updated Jun 19, 2001.

This patch removes a warning in the compilation of mg.c; there is no third
argument to setproctitle() - though apparently it accepts it with a warning.

This removes the third argument from the use of the function, resolving the
warning.

As an interesting note, the setproctitle man page states that it is possible
that other forms of setproctitle() exist out there, but none have been seen. 

It is dated December 16, 1995.

All tests passed.

R.

--- mg.c~	Sat Jul 28 22:57:04 2001
+++ mg.c	Sat Jul 28 22:56:45 2001
@@ -2089,7 +2089,7 @@
 	     * but not the "(perl) suffix from the ps(1)
 	     * output, because that's what ps(1) shows if the
 	     * argv[] is modified. */
-	    setproctitle("-%s", s, len + 1);
+	    setproctitle("-%s", s);
 #   else	/* old FreeBSDs, NetBSD, OpenBSD, anyBSD */
 	    /* This doesn't really work if you assume that
 	     * $0 = 'foobar'; will wipe out 'perl' from the $0




Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About