diff options
Diffstat (limited to 'generic/tkCanvLine.c')
-rw-r--r-- | generic/tkCanvLine.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/generic/tkCanvLine.c b/generic/tkCanvLine.c index 9d68c37..087aa56 100644 --- a/generic/tkCanvLine.c +++ b/generic/tkCanvLine.c @@ -1743,11 +1743,10 @@ GetLineIndex( int *indexPtr) /* Where to store converted index. */ { LineItem *linePtr = (LineItem *) itemPtr; - int length; - const char *string = Tcl_GetStringFromObj(obj, &length); + const char *string = Tcl_GetString(obj); if (string[0] == 'e') { - if (strncmp(string, "end", (unsigned) length) == 0) { + if (strncmp(string, "end", obj->length) == 0) { *indexPtr = 2*linePtr->numPoints; } else { goto badIndex; |