projects
/
fw
/
pdclib
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Fixed end-of-string bug. Thanks to Paul Barker for reporting this.
[fw/pdclib]
/
functions
/
string
/
strncmp.c
diff --git
a/functions/string/strncmp.c
b/functions/string/strncmp.c
index cbd16e4fe83ab305ad550f1ecd5ac5acca5b545e..0d1e7f036922c963df4e0dfc1420e3510fd82f43 100644
(file)
--- a/
functions/string/strncmp.c
+++ b/
functions/string/strncmp.c
@@
-12,7
+12,7
@@
int strncmp( const char * s1, const char * s2, size_t n )
{
- while ( n && ( *s1 == *s2 ) )
+ while ( n &&
*s1 &&
( *s1 == *s2 ) )
{
++s1;
++s2;