From: Kurt Zeilenga Date: Fri, 11 Oct 2002 19:18:00 +0000 (+0000) Subject: fix snprintf result handling X-Git-Tag: OPENLDAP_REL_ENG_2_1_6~4 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=2a2966aa6235c8de53830c6f716f537761efca2f;p=openldap fix snprintf result handling --- diff --git a/libraries/liblutil/uuid.c b/libraries/liblutil/uuid.c index 81be614358..d85f6f139a 100644 --- a/libraries/liblutil/uuid.c +++ b/libraries/liblutil/uuid.c @@ -273,7 +273,7 @@ lutil_uuidstr( char *buf, size_t len ) (unsigned) nl[2], (unsigned) nl[3], (unsigned) nl[4], (unsigned) nl[5] ); - return (t1 < len) ? t1 : 0; + return (0 < t1 && t1 < len) ? t1 : 0; #endif }