svn commit: branches/busybox_1_6_stable/coreutils

aldot at busybox.net aldot at busybox.net
Fri Jun 8 05:51:56 PDT 2007


Author: aldot
Date: 2007-06-08 05:51:55 -0700 (Fri, 08 Jun 2007)
New Revision: 18778

Log:
- fix invocation without any argument


Modified:
   branches/busybox_1_6_stable/coreutils/echo.c


Changeset:
Modified: branches/busybox_1_6_stable/coreutils/echo.c
===================================================================
--- branches/busybox_1_6_stable/coreutils/echo.c	2007-06-08 08:02:53 UTC (rev 18777)
+++ branches/busybox_1_6_stable/coreutils/echo.c	2007-06-08 12:51:55 UTC (rev 18778)
@@ -34,6 +34,8 @@
 		nflag = 1,  /* 1 -- print '\n' */
 	};
 	arg = *++argv;
+	if (!arg)
+		goto newline_ret;
 #else
 	const char *p;
 	char nflag = 1;
@@ -107,9 +109,7 @@
 		putchar(' ');
 	}
 
-#if ENABLE_FEATURE_FANCY_ECHO
  newline_ret:
-#endif
 	if (nflag) {
 		putchar('\n');
 	}



More information about the busybox-cvs mailing list