diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-02-01 15:49:33 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-02-01 15:49:33 (GMT) |
commit | 266897fcf4c3441f12348d643b18a2d63e37f8aa (patch) | |
tree | e0af1794b6829d3f838125af8b8c1f94632a35fc /generic/tkCanvas.c | |
parent | 4b2f498d2f6aea8e320ecf6e45508b93ed3ba89e (diff) | |
download | tk-266897fcf4c3441f12348d643b18a2d63e37f8aa.zip tk-266897fcf4c3441f12348d643b18a2d63e37f8aa.tar.gz tk-266897fcf4c3441f12348d643b18a2d63e37f8aa.tar.bz2 |
some more int -> size_t changes
Diffstat (limited to 'generic/tkCanvas.c')
-rw-r--r-- | generic/tkCanvas.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/generic/tkCanvas.c b/generic/tkCanvas.c index 6972b18..23d8e04 100644 --- a/generic/tkCanvas.c +++ b/generic/tkCanvas.c @@ -1242,14 +1242,15 @@ CanvasWidgetCmd( int isNew = 0; Tcl_HashEntry *entryPtr; const char *arg; - int length; + size_t length; if (objc < 3) { Tcl_WrongNumArgs(interp, 2, objv, "type coords ?arg ...?"); result = TCL_ERROR; goto done; } - arg = Tcl_GetStringFromObj(objv[2], &length); + arg = Tcl_GetString(objv[2]); + length = objv[2]->length; c = arg[0]; /* @@ -1261,7 +1262,7 @@ CanvasWidgetCmd( Tcl_MutexLock(&typeListMutex); for (typePtr = typeList; typePtr != NULL; typePtr = typePtr->nextPtr){ if ((c == typePtr->name[0]) - && (!strncmp(arg, typePtr->name, (unsigned)length))) { + && (!strncmp(arg, typePtr->name, length))) { if (matchPtr != NULL) { Tcl_MutexUnlock(&typeListMutex); goto badType; |