summaryrefslogtreecommitdiffstats
path: root/generic/tkPack.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2013-02-01 15:49:33 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2013-02-01 15:49:33 (GMT)
commit6c9d67ac2ce6b610bb42688c03d6abf8e99f2a6b (patch)
treee0af1794b6829d3f838125af8b8c1f94632a35fc /generic/tkPack.c
parent88df780305133662dbb17971c05b9663a2b69f9d (diff)
downloadtk-6c9d67ac2ce6b610bb42688c03d6abf8e99f2a6b.zip
tk-6c9d67ac2ce6b610bb42688c03d6abf8e99f2a6b.tar.gz
tk-6c9d67ac2ce6b610bb42688c03d6abf8e99f2a6b.tar.bz2
some more int -> size_t changes
Diffstat (limited to 'generic/tkPack.c')
-rw-r--r--generic/tkPack.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/generic/tkPack.c b/generic/tkPack.c
index 8428f09..88a4b2d 100644
--- a/generic/tkPack.c
+++ b/generic/tkPack.c
@@ -1101,7 +1101,6 @@ PackAfter(
{
register Packer *packPtr;
Tk_Window tkwin, ancestor, parent;
- int length;
Tcl_Obj **options;
int index, optionCount, c;
@@ -1170,24 +1169,25 @@ PackAfter(
packPtr->flags |= OLD_STYLE;
for (index = 0 ; index < optionCount; index++) {
Tcl_Obj *curOptPtr = options[index];
- const char *curOpt = Tcl_GetStringFromObj(curOptPtr, &length);
+ const char *curOpt = Tcl_GetString(curOptPtr);
+ size_t length = curOptPtr->length;
c = curOpt[0];
if ((c == 't')
- && (strncmp(curOpt, "top", (size_t) length)) == 0) {
+ && (strncmp(curOpt, "top", length)) == 0) {
packPtr->side = TOP;
} else if ((c == 'b')
- && (strncmp(curOpt, "bottom", (size_t) length)) == 0) {
+ && (strncmp(curOpt, "bottom", length)) == 0) {
packPtr->side = BOTTOM;
} else if ((c == 'l')
- && (strncmp(curOpt, "left", (size_t) length)) == 0) {
+ && (strncmp(curOpt, "left", length)) == 0) {
packPtr->side = LEFT;
} else if ((c == 'r')
- && (strncmp(curOpt, "right", (size_t) length)) == 0) {
+ && (strncmp(curOpt, "right", length)) == 0) {
packPtr->side = RIGHT;
} else if ((c == 'e')
- && (strncmp(curOpt, "expand", (size_t) length)) == 0) {
+ && (strncmp(curOpt, "expand", length)) == 0) {
packPtr->flags |= EXPAND;
} else if ((c == 'f')
&& (strcmp(curOpt, "fill")) == 0) {