summaryrefslogtreecommitdiffstats
path: root/generic/tclDisassemble.c
diff options
context:
space:
mode:
authorsebres <sebres@users.sourceforge.net>2018-02-09 10:09:42 (GMT)
committersebres <sebres@users.sourceforge.net>2018-02-09 10:09:42 (GMT)
commit0031252bf124749bd39e94427d50a954cb3bc762 (patch)
treebb096df791e546a9b6869aab5f4b7553fbe5a269 /generic/tclDisassemble.c
parent4d73b33b87caab45e34298560f16e200c7374d66 (diff)
downloadtcl-0031252bf124749bd39e94427d50a954cb3bc762.zip
tcl-0031252bf124749bd39e94427d50a954cb3bc762.tar.gz
tcl-0031252bf124749bd39e94427d50a954cb3bc762.tar.bz2
small code review: resolve conversion warnings (possible loss of data, signed/unsigned comparison)
Diffstat (limited to 'generic/tclDisassemble.c')
-rw-r--r--generic/tclDisassemble.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclDisassemble.c b/generic/tclDisassemble.c
index 73b8fb9..7fe92ef 100644
--- a/generic/tclDisassemble.c
+++ b/generic/tclDisassemble.c
@@ -817,7 +817,7 @@ static void
UpdateStringOfInstName(
Tcl_Obj *objPtr)
{
- int inst = objPtr->internalRep.wideValue;
+ int inst = (int)objPtr->internalRep.wideValue;
char *s, buf[20];
int len;
@@ -825,7 +825,7 @@ UpdateStringOfInstName(
sprintf(buf, "inst_%d", inst);
s = buf;
} else {
- s = (char *) tclInstructionTable[objPtr->internalRep.wideValue].name;
+ s = (char *) tclInstructionTable[inst].name;
}
len = strlen(s);
objPtr->bytes = ckalloc(len + 1);