This is an automated email from the ASF dual-hosted git repository. astitcher pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/qpid-proton.git
commit 3d6c8c4d21070af86c8c130e119257cfdc30e6fe Author: Andrew Stitcher <astitc...@apache.org> AuthorDate: Wed Oct 27 17:56:16 2021 -0400 PROTON-2444: Fix potential use of uninitialised value --- c/src/core/util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/c/src/core/util.c b/c/src/core/util.c index bed2a54..70a3fe6 100644 --- a/c/src/core/util.c +++ b/c/src/core/util.c @@ -98,7 +98,7 @@ int pn_strcasecmp(const char *a, const char *b) int pn_strncasecmp(const char* a, const char* b, size_t len) { int diff = 0; - while (*b && len > 0) { + while (len > 0 && *b) { char aa = *a++, bb = *b++; diff = tolower(aa)-tolower(bb); if ( diff!=0 ) return diff; --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@qpid.apache.org For additional commands, e-mail: commits-h...@qpid.apache.org