diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-04-26 19:29:44 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2023-04-26 19:29:44 (GMT) |
commit | 372bf743344195cfcf84a7c71e9891071184b867 (patch) | |
tree | 5395355f4ddee4e279b3f119dc73078315cc0a2e /generic/tclObj.c | |
parent | cd51753d86cde24e24f0fa1c6edf6821ba25d0aa (diff) | |
download | tcl-372bf743344195cfcf84a7c71e9891071184b867.zip tcl-372bf743344195cfcf84a7c71e9891071184b867.tar.gz tcl-372bf743344195cfcf84a7c71e9891071184b867.tar.bz2 |
Reduce number of needed type-casts. No change in functionality
Diffstat (limited to 'generic/tclObj.c')
-rw-r--r-- | generic/tclObj.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclObj.c b/generic/tclObj.c index 9d27fca..0c9c405 100644 --- a/generic/tclObj.c +++ b/generic/tclObj.c @@ -1670,7 +1670,7 @@ char * TclGetStringFromObj( Tcl_Obj *objPtr, /* Object whose string rep byte pointer should * be returned. */ - int *lengthPtr) /* If non-NULL, the location where the string + void *lengthPtr) /* If non-NULL, the location where the string * rep's byte array length should * be stored. * If NULL, no length is stored. */ { @@ -1704,7 +1704,7 @@ TclGetStringFromObj( Tcl_Panic("Tcl_GetStringFromObj with 'int' lengthPtr" " cannot handle such long strings. Please use 'Tcl_Size'"); } - *lengthPtr = (int)objPtr->length; + *(int *)lengthPtr = (int)objPtr->length; } return objPtr->bytes; } |