diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-12-08 10:35:18 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-12-08 10:35:18 (GMT) |
commit | 26680f78efed6ca9cd37c75846bf2ea5af8a76aa (patch) | |
tree | 6d05173b04d18e1f029faec7dfb5ca6ff9b6bcb1 /generic | |
parent | ba13f552d3a716347686f09fe59bb602c1eaae19 (diff) | |
parent | 35231ec0d7e1ee42dedbc1c26152e097589659fb (diff) | |
download | tcl-26680f78efed6ca9cd37c75846bf2ea5af8a76aa.zip tcl-26680f78efed6ca9cd37c75846bf2ea5af8a76aa.tar.gz tcl-26680f78efed6ca9cd37c75846bf2ea5af8a76aa.tar.bz2 |
Merge 8.7
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclStubLib.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/generic/tclStubLib.c b/generic/tclStubLib.c index 9381532..5624a8a 100644 --- a/generic/tclStubLib.c +++ b/generic/tclStubLib.c @@ -54,10 +54,11 @@ Tcl_InitStubs( int exact, int magic) { - Interp *iPtr = (Interp *) interp; + Interp *iPtr = (Interp *)interp; const char *actualVersion = NULL; ClientData pkgData = NULL; const TclStubs *stubsPtr = iPtr->stubTable; + const char *tclName = (((exact&0xFF00) >= 0x900) ? "tcl" : "Tcl"); /* * We can't optimize this check by caching tclStubsPtr because that @@ -71,7 +72,7 @@ Tcl_InitStubs( return NULL; } - actualVersion = stubsPtr->tcl_PkgRequireEx(interp, "Tcl", version, 0, &pkgData); + actualVersion = stubsPtr->tcl_PkgRequireEx(interp, tclName, version, 0, &pkgData); if (actualVersion == NULL) { return NULL; } @@ -91,11 +92,11 @@ Tcl_InitStubs( } if (*p || ISDIGIT(*q)) { /* Construct error message */ - stubsPtr->tcl_PkgRequireEx(interp, "Tcl", version, 1, NULL); + stubsPtr->tcl_PkgRequireEx(interp, tclName, version, 1, NULL); return NULL; } } else { - actualVersion = stubsPtr->tcl_PkgRequireEx(interp, "Tcl", version, 1, NULL); + actualVersion = stubsPtr->tcl_PkgRequireEx(interp, tclName, version, 1, NULL); if (actualVersion == NULL) { return NULL; } |