aboutsummaryrefslogtreecommitdiff
path: root/payloads
diff options
context:
space:
mode:
authorStefan Reinauer <stepan@coresystems.de>2009-03-06 17:43:20 +0000
committerStefan Reinauer <stepan@openbios.org>2009-03-06 17:43:20 +0000
commit0d348f919cc19841e76762be1c42c4c2737bd268 (patch)
tree761a229571cdfb73f9d6544c73fe8c6de73721d9 /payloads
parent8dcd50b15558dd2e3ee509779dd39b7f385238f4 (diff)
fix strstr. Seems the function never worked before, except the searched
substring is at the end. Signed-off-by: Stefan Reinauer <stepan@coresystems.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3978 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'payloads')
-rw-r--r--payloads/libpayload/libc/string.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/payloads/libpayload/libc/string.c b/payloads/libpayload/libc/string.c
index b9ecb907f6..ec6be1dfb4 100644
--- a/payloads/libpayload/libc/string.c
+++ b/payloads/libpayload/libc/string.c
@@ -234,7 +234,7 @@ char *strstr(const char *h, const char *n)
int i;
for (i = 0; i <= hn - nn; i++)
- if (!strcmp(&h[i], n))
+ if (!memcmp(&h[i], n, nn))
return (char *)&h[i];
return NULL;