svn commit: r297888 - head/lib/libc/gen

Ed Maste emaste at FreeBSD.org
Tue Apr 12 22:59:22 UTC 2016


Author: emaste
Date: Tue Apr 12 22:59:20 2016
New Revision: 297888
URL: https://svnweb.freebsd.org/changeset/base/297888

Log:
  Remove PS_STRINGS fallback from setproctitle
  
  In r103767 the kern.ps_strings sysctl was added as the preferred way to
  locate the ps_strings struct and is available in any FreeBSD release
  supported within the last decade.
  
  Reviewed by:	kib

Modified:
  head/lib/libc/gen/setproctitle.c

Modified: head/lib/libc/gen/setproctitle.c
==============================================================================
--- head/lib/libc/gen/setproctitle.c	Tue Apr 12 22:58:40 2016	(r297887)
+++ head/lib/libc/gen/setproctitle.c	Tue Apr 12 22:59:20 2016	(r297888)
@@ -134,7 +134,7 @@ setproctitle(const char *fmt, ...)
 		len = sizeof(ul_ps_strings);
 		if (sysctlbyname("kern.ps_strings", &ul_ps_strings, &len, NULL,
 		    0) == -1)
-			ul_ps_strings = PS_STRINGS;
+			return;
 		ps_strings = (struct ps_strings *)ul_ps_strings;
 	}
 


More information about the svn-src-head mailing list