any -> index (use the faster library routine)
authorKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Fri, 15 Mar 1991 04:30:31 +0000 (20:30 -0800)
committerKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Fri, 15 Mar 1991 04:30:31 +0000 (20:30 -0800)
SCCS-vsn: bin/csh/sem.c 5.9

usr/src/bin/csh/sem.c

index 55d3914..8dbbe53 100644 (file)
@@ -5,7 +5,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char *sccsid = "@(#)sem.c       5.8 (Berkeley) %G%";
+static char *sccsid = "@(#)sem.c       5.9 (Berkeley) %G%";
 #endif
 
 #include "sh.h"
 #endif
 
 #include "sh.h"
@@ -73,7 +73,7 @@ execute(t, wanttty, pipein, pipeout)
                while (t->t_dtyp == TCOM)
                        if (eq(t->t_dcom[0], "nice"))
                                if (t->t_dcom[1])
                while (t->t_dtyp == TCOM)
                        if (eq(t->t_dcom[0], "nice"))
                                if (t->t_dcom[1])
-                                       if (any(t->t_dcom[1][0], "+-"))
+                                       if (index("+-", t->t_dcom[1][0]))
                                                if (t->t_dcom[2]) {
                                                        setname("nice");
                                                        t->t_nice = getn(t->t_dcom[1]);
                                                if (t->t_dcom[2]) {
                                                        setname("nice");
                                                        t->t_nice = getn(t->t_dcom[1]);