diff options
author | Miguel Sofer <miguel.sofer@gmail.com> | 2006-09-24 21:15:09 (GMT) |
---|---|---|
committer | Miguel Sofer <miguel.sofer@gmail.com> | 2006-09-24 21:15:09 (GMT) |
commit | e9357cfedeca25e77bab05b6d8da9e7579b2d774 (patch) | |
tree | 52642af6e3fb2c29a09534224d480bb89536d396 /generic/tclParse.c | |
parent | 004129769739631f0ad158d5c98851ae5705b58a (diff) | |
download | tcl-e9357cfedeca25e77bab05b6d8da9e7579b2d774.zip tcl-e9357cfedeca25e77bab05b6d8da9e7579b2d774.tar.gz tcl-e9357cfedeca25e77bab05b6d8da9e7579b2d774.tar.bz2 |
* generic/tclParse.c (Tcl_ParseCommand): also return an error if
start==NULL and numBytes<0. This is coverity's bug #20
* generic/tclStringObj.c (STRING_SIZE): fix allocation for
0-length strings. This is coverity's bugs #54-5
Diffstat (limited to 'generic/tclParse.c')
-rw-r--r-- | generic/tclParse.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclParse.c b/generic/tclParse.c index ec8c9f0..fc7a77c 100644 --- a/generic/tclParse.c +++ b/generic/tclParse.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclParse.c,v 1.25 2003/02/16 01:36:32 msofer Exp $ + * RCS: @(#) $Id: tclParse.c,v 1.25.2.1 2006/09/24 21:15:10 msofer Exp $ */ #include "tclInt.h" @@ -238,7 +238,7 @@ Tcl_ParseCommand(interp, string, numBytes, nested, parsePtr) * point to char after terminating one. */ int scanned; - if ((string == NULL) && (numBytes>0)) { + if ((string == NULL) && (numBytes!=0)) { if (interp != NULL) { Tcl_SetResult(interp, "can't parse a NULL pointer", TCL_STATIC); } |