Index: generic/tclCmdAH.c
===================================================================
RCS file: /cvsroot/tcl/tcl/generic/tclCmdAH.c,v
retrieving revision 1.27.2.13
diff -u -r1.27.2.13 tclCmdAH.c
--- generic/tclCmdAH.c	5 Jul 2005 21:18:23 -0000	1.27.2.13
+++ generic/tclCmdAH.c	12 Sep 2005 01:52:56 -0000
@@ -2193,9 +2193,12 @@
 		size = 40 + precision;
 		break;
 	    }
-	    if (Tcl_GetLongFromObj(interp,		/* INTL: Tcl source. */
-		    objv[objIndex], &intValue) != TCL_OK) {
-		goto fmtError;
+	    if (Tcl_GetLongFromObj(NULL, objv[objIndex], &intValue) != TCL_OK) {
+		if (Tcl_GetWideIntFromObj(interp, objv[objIndex], &wideValue)
+			!= TCL_OK) {
+		    goto fmtError;
+		}
+		intValue = Tcl_WideAsLong(wideValue);
 	    }
 
 #if (LONG_MAX > INT_MAX)
