--- tcl8.3.3/generic/tclCmdAH.c
+++ tcl8.3.3/generic/tclCmdAH.c
@@ -1930,7 +1930,7 @@
     int size;			/* Number of bytes needed for result of
 				 * conversion, based on type of conversion
 				 * ("e", "s", etc.), width, and precision. */
-    int intValue;		/* Used to hold value to pass to sprintf, if
+    long intValue;		/* Used to hold value to pass to sprintf, if
 				 * it's a one-word integer or char value */
     char *ptrValue = NULL;	/* Used to hold value to pass to sprintf, if
 				 * it's a one-word value. */
@@ -2166,10 +2166,16 @@
 	    case 'u':
 	    case 'x':
 	    case 'X':
-		if (Tcl_GetIntFromObj(interp,	/* INTL: Tcl source. */
+		if (Tcl_GetLongFromObj(interp,	/* INTL: Tcl source. */
 			objv[objIndex], &intValue) != TCL_OK) {
 		    goto fmtError;
 		}
+		if ((unsigned long) intValue > UINT_MAX) {
+			newPtr++;
+			*newPtr = 0;
+			newPtr[-1] = newPtr[-2];
+			newPtr[-2] = 'l';
+		}
 		whichValue = INT_VALUE;
 		size = 40 + precision;
 		break;
@@ -2193,7 +2199,7 @@
 		}
 		break;
 	    case 'c':
-		if (Tcl_GetIntFromObj(interp,	/* INTL: Tcl source. */
+		if (Tcl_GetLongFromObj(interp,	/* INTL: Tcl source. */
 			objv[objIndex], &intValue) != TCL_OK) {
 		    goto fmtError;
 		}
--- tcl8.3.3/generic/tclScan.c
+++ tcl8.3.3/generic/tclScan.c
@@ -539,7 +539,8 @@
 {
     char *format;
     int numVars, nconversions, totalVars = -1;
-    int objIndex, offset, i, value, result, code;
+    int objIndex, offset, i, result, code;
+    long value;
     char *string, *end, *baseString;
     char op = 0;
     int base = 0;
@@ -954,12 +955,16 @@
 
 		if (!(flags & SCAN_SUPPRESS)) {
 		    *end = '\0';
-		    value = (int) (*fn)(buf, NULL, base);
+		    value = (long) (*fn)(buf, NULL, base);
 		    if ((flags & SCAN_UNSIGNED) && (value < 0)) {
-			sprintf(buf, "%u", value); /* INTL: ISO digit */
+			sprintf(buf, "%lu", value); /* INTL: ISO digit */
 			objPtr = Tcl_NewStringObj(buf, -1);
 		    } else {
-			objPtr = Tcl_NewIntObj(value);
+			if ((unsigned long) value > UINT_MAX) {
+				objPtr = Tcl_NewLongObj(value);
+			} else {
+				objPtr = Tcl_NewIntObj(value);
+			}
 		    }
 		    Tcl_IncrRefCount(objPtr);
 		    objs[objIndex++] = objPtr;
