ppcrcd/trunk/yaboot/lib/strstr.c

sparky cvs at pld-linux.org
Sat Feb 25 20:53:28 CET 2006


Author: sparky
Date: Sat Feb 25 20:53:25 2006
New Revision: 7012

Modified:
   ppcrcd/trunk/yaboot/lib/strstr.c
Log:
- use 1.3.14rc1 file


Modified: ppcrcd/trunk/yaboot/lib/strstr.c
==============================================================================
--- ppcrcd/trunk/yaboot/lib/strstr.c	(original)
+++ ppcrcd/trunk/yaboot/lib/strstr.c	Sat Feb 25 20:53:25 2006
@@ -65,18 +65,8 @@
         {
           register chartype a;
 	  register const unsigned char *rhaystack, *rneedle;
-	  
-	  a = *++haystack;
-	  if (a == '\0')
-	      goto ret0;
-	  if (a == b)
-              break;
-	  a = *++haystack;
-	  if (a == '\0')
-              goto ret0;
 
-	 do {
-	  while (a != b)
+	  do
 	    {
 	      a = *++haystack;
 	      if (a == '\0')
@@ -86,13 +76,16 @@
 	      a = *++haystack;
 	      if (a == '\0')
 		goto ret0;
-	    }
+shloop:	    ;
+            }
+          while (a != b);
 
 jin:	  a = *++haystack;
 	  if (a == '\0')
 	    goto ret0;
 
-	} while ( a != c );
+	  if (a != c)
+	    goto shloop;
 
 	  rhaystack = haystack-- + 1;
 	  rneedle = needle;


More information about the pld-cvs-commit mailing list