[BusyBox] Small and tiny ps_main.c modification

Christophe Boyanique totof at raceme.org
Thu Apr 12 13:37:06 UTC 2001


Here is a ridiculous patch to ps_main.c to harmonize options parsing error
with the 2 ps versions (with or without kernel devps patch).

Why am I bothering with that ? Because I'm preparing a new version for my
patch to add (optional) parameters to ps.

Christophe.
-------------- next part --------------
diff -ur busybox-0.51.orig/ps.c busybox-0.51/ps.c
--- busybox-0.51.orig/ps.c	Tue Feb 20 07:14:08 2001
+++ busybox-0.51/ps.c	Thu Apr 12 15:28:18 2001
@@ -129,7 +129,8 @@
 #define terminal_width  TERMINAL_WIDTH
 #endif
 
-
+	if (argc > 1 && **(argv + 1) == '-') 
+		show_usage();
 
 	dir = opendir("/proc");
 	if (!dir)


More information about the busybox mailing list