diff options
| author | donal.k.fellows@manchester.ac.uk <dkf> | 2001-08-23 14:22:49 (GMT) |
|---|---|---|
| committer | donal.k.fellows@manchester.ac.uk <dkf> | 2001-08-23 14:22:49 (GMT) |
| commit | d5d35f57efcb1118b53895b5c1420ef7f6b75d49 (patch) | |
| tree | 6fa3cc7a93c57b5abdec868f69e6dc434a60ff47 /generic/tclBinary.c | |
| parent | 77f09c1f7db57d7d1f9e57cd5899bbebaa996734 (diff) | |
| download | tcl-d5d35f57efcb1118b53895b5c1420ef7f6b75d49.zip tcl-d5d35f57efcb1118b53895b5c1420ef7f6b75d49.tar.gz tcl-d5d35f57efcb1118b53895b5c1420ef7f6b75d49.tar.bz2 | |
Fixed annoying fault in [binary format] on 64-bit architectures.
Diffstat (limited to 'generic/tclBinary.c')
| -rw-r--r-- | generic/tclBinary.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclBinary.c b/generic/tclBinary.c index e0facb5..9fd9f4d 100644 --- a/generic/tclBinary.c +++ b/generic/tclBinary.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclBinary.c,v 1.7 2001/04/04 16:07:20 kennykb Exp $ + * RCS: @(#) $Id: tclBinary.c,v 1.8 2001/08/23 14:22:49 dkf Exp $ */ #include <math.h> @@ -1393,7 +1393,7 @@ FormatNumber(interp, type, src, cursorPtr) Tcl_Obj *src; /* Number to format. */ unsigned char **cursorPtr; /* Pointer to index into destination buffer. */ { - int value; + long value; double dvalue; if ((type == 'd') || (type == 'f')) { @@ -1426,7 +1426,7 @@ FormatNumber(interp, type, src, cursorPtr) *cursorPtr += sizeof(float); } } else { - if (Tcl_GetIntFromObj(interp, src, &value) != TCL_OK) { + if (Tcl_GetLongFromObj(interp, src, &value) != TCL_OK) { return TCL_ERROR; } if (type == 'c') { |
