From: Anthony Minessale Date: Thu, 23 Jul 2009 14:52:23 +0000 (+0000) Subject: zero out buffer on (null) X-Git-Tag: v1.0.4~124 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a482decfac0ec84d46362649547f5d02ef1920fd;p=thirdparty%2Ffreeswitch.git zero out buffer on (null) git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@14328 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- diff --git a/src/switch_core_db.c b/src/switch_core_db.c index e675569aa5..db97a8e81f 100644 --- a/src/switch_core_db.c +++ b/src/switch_core_db.c @@ -59,8 +59,9 @@ SWITCH_DECLARE(const unsigned char *) switch_core_db_column_text(switch_core_db_ { const unsigned char *txt = sqlite3_column_text(stmt, iCol); - if (txt && !strcasecmp((char *)txt, "(null)")) { - txt = NULL; + if (!strcasecmp((char *)stmt, "(null)")) { + memset(stmt, 0, 1); + txt = NULL; } return txt;