summaryrefslogtreecommitdiffstats
path: root/nsprpub/lib/libc/src/strcmp.c
diff options
context:
space:
mode:
authorwolfbeast <mcwerewolf@wolfbeast.com>2020-01-02 21:01:38 +0100
committerwolfbeast <mcwerewolf@wolfbeast.com>2020-01-02 21:01:38 +0100
commitf7d30133221896638f7bf4f66c504255c4b14f48 (patch)
tree5f3e07a049f388a3a309a615b8884318f6668a98 /nsprpub/lib/libc/src/strcmp.c
parent26b297510a11758727438df4669357a2a2bc42ce (diff)
downloadUXP-f7d30133221896638f7bf4f66c504255c4b14f48.tar
UXP-f7d30133221896638f7bf4f66c504255c4b14f48.tar.gz
UXP-f7d30133221896638f7bf4f66c504255c4b14f48.tar.lz
UXP-f7d30133221896638f7bf4f66c504255c4b14f48.tar.xz
UXP-f7d30133221896638f7bf4f66c504255c4b14f48.zip
Issue #1338 - Part 1: Update NSPR to 4.24
Diffstat (limited to 'nsprpub/lib/libc/src/strcmp.c')
-rw-r--r--nsprpub/lib/libc/src/strcmp.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/nsprpub/lib/libc/src/strcmp.c b/nsprpub/lib/libc/src/strcmp.c
index 296d71631..9b00bbc52 100644
--- a/nsprpub/lib/libc/src/strcmp.c
+++ b/nsprpub/lib/libc/src/strcmp.c
@@ -9,10 +9,12 @@
PR_IMPLEMENT(PRIntn)
PL_strcmp(const char *a, const char *b)
{
- if( (const char *)0 == a )
+ if( (const char *)0 == a ) {
return ((const char *)0 == b) ? 0 : -1;
- if( (const char *)0 == b )
+ }
+ if( (const char *)0 == b ) {
return 1;
+ }
return (PRIntn)strcmp(a, b);
}
@@ -20,10 +22,12 @@ PL_strcmp(const char *a, const char *b)
PR_IMPLEMENT(PRIntn)
PL_strncmp(const char *a, const char *b, PRUint32 max)
{
- if( (const char *)0 == a )
+ if( (const char *)0 == a ) {
return ((const char *)0 == b) ? 0 : -1;
- if( (const char *)0 == b )
+ }
+ if( (const char *)0 == b ) {
return 1;
+ }
return (PRIntn)strncmp(a, b, (size_t)max);
}