svn commit: trunk/busybox/coreutils

aldot at busybox.net aldot at busybox.net
Tue Jun 12 13:21:09 UTC 2007


Author: aldot
Date: 2007-06-12 06:21:08 -0700 (Tue, 12 Jun 2007)
New Revision: 18801

Log:
- fix testing primary expressions like '"-u" = "-u"'


Modified:
   trunk/busybox/coreutils/test.c


Changeset:
Modified: trunk/busybox/coreutils/test.c
===================================================================
--- trunk/busybox/coreutils/test.c	2007-06-12 08:52:02 UTC (rev 18800)
+++ trunk/busybox/coreutils/test.c	2007-06-12 13:21:08 UTC (rev 18801)
@@ -224,7 +224,7 @@
 	if (argc == 2)
 		return *argv[1] == '\0';
 //assert(argc);
-	if (LONE_CHAR(argv[1], '!')) {
+	{
 		bool _off;
 		if (argc == 3)
 			return *argv[2] != '\0';
@@ -232,7 +232,7 @@
 		t_lex(argv[2 + _off]);
 		if (t_wp_op && t_wp_op->op_type == BINOP) {
 			t_wp = &argv[1 + _off];
-			return binop() == 1;
+			return binop() == (LONE_CHAR(argv[1], '!'));
 		}
 	}
 	t_wp = &argv[1];




More information about the busybox-cvs mailing list