aboutsummaryrefslogtreecommitdiff
path: root/utility.c
diff options
context:
space:
mode:
Diffstat (limited to 'utility.c')
-rw-r--r--utility.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/utility.c b/utility.c
index e0f9d1246..637368740 100644
--- a/utility.c
+++ b/utility.c
@@ -777,7 +777,7 @@ int get_console_fd(char* tty_name)
777#endif 777#endif
778 778
779 779
780#if !defined BB_REGEXP && (defined BB_GREP || defined BB_FIND ) 780#if !defined BB_REGEXP && (defined BB_GREP || defined BB_FIND || defined BB_SED)
781 781
782/* Do a case insensitive strstr() */ 782/* Do a case insensitive strstr() */
783char* stristr(char *haystack, const char *needle) 783char* stristr(char *haystack, const char *needle)
@@ -817,7 +817,7 @@ extern int find_match(char *haystack, char *needle, int ignoreCase)
817/* This performs substitutions after a string match has been found. */ 817/* This performs substitutions after a string match has been found. */
818extern int replace_match(char *haystack, char *needle, char *newNeedle, int ignoreCase) 818extern int replace_match(char *haystack, char *needle, char *newNeedle, int ignoreCase)
819{ 819{
820 int foundOne; 820 int foundOne=0;
821 char *where, *slider, *slider1, *oldhayStack; 821 char *where, *slider, *slider1, *oldhayStack;
822 822
823 if (ignoreCase == FALSE) 823 if (ignoreCase == FALSE)
@@ -847,7 +847,7 @@ extern int replace_match(char *haystack, char *needle, char *newNeedle, int igno
847 } 847 }
848 free( oldhayStack); 848 free( oldhayStack);
849 849
850 if (foundOne) 850 if (foundOne > 0)
851 return TRUE; 851 return TRUE;
852 else 852 else
853 return FALSE; 853 return FALSE;