[Pcsclite-cvs-commit] r6229 - /trunk/PCSC/src/debuglog.c

rousseau at users.alioth.debian.org rousseau at users.alioth.debian.org
Tue Feb 21 08:49:22 UTC 2012


Author: rousseau
Date: Tue Feb 21 08:49:21 2012
New Revision: 6229

URL: http://svn.debian.org/wsvn/pcsclite/?sc=1&rev=6229
Log:
log_xxd(): do not log with negative length

Thanks to Godfrey Chung for the bug report
http://archives.neohapsis.com/archives/dev/muscle/2012-q1/0043.html

Modified:
    trunk/PCSC/src/debuglog.c

Modified: trunk/PCSC/src/debuglog.c
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/src/debuglog.c?rev=6229&op=diff
==============================================================================
--- trunk/PCSC/src/debuglog.c (original)
+++ trunk/PCSC/src/debuglog.c Tue Feb 21 08:49:21 2012
@@ -202,6 +202,10 @@
 		|| (DEBUGLOG_NO_DEBUG == LogMsgType))
 		return;
 
+	/* len is an error value? */
+	if (len < 0)
+		return;
+
 	log_xxd_always(priority, msg, buffer, len);
 } /* log_xxd */
 




More information about the Pcsclite-cvs-commit mailing list