[PATCH] replace findstring with filter

Robert P. J. Day rpjday at mindspring.com
Fri May 12 12:39:06 UTC 2006


  technically, filter is safer here since it matches based on entire
words whereas findstring might match substrings (unlikely to actually
cause a problem but why live dangerously?)

rday
-------------- next part --------------
diff -pru busybox/libbb/Makefile.in busybox.new/libbb/Makefile.in
--- busybox/libbb/Makefile.in	2006-05-12 07:32:19.000000000 -0400
+++ busybox.new/libbb/Makefile.in	2006-05-12 08:37:49.000000000 -0400
@@ -116,10 +116,10 @@ LIBBB_AR:=$(LIBBB_DIR)/libbb.a
 libraries-y+=$(LIBBB_AR)
 
 needcrypt-y:=
-ifneq ($(findstring $(srcdir)/pw_encrypt.c,$(LIBBB-y)),)
+ifneq ($(filter $(srcdir)/pw_encrypt.c,$(LIBBB-y)),)
 needcrypt-y:=y
 else
-ifneq ($(findstring $(srcdir)/correct_password.c,$(LIBBB-y)),)
+ifneq ($(filter $(srcdir)/correct_password.c,$(LIBBB-y)),)
 needcrypt-y:=y
 endif
 endif


More information about the busybox mailing list