summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2012-12-07 18:08:48 (GMT)
committerdgp <dgp@users.sourceforge.net>2012-12-07 18:08:48 (GMT)
commitf21757bb59b183ee82e709542e8d741db5648e9a (patch)
treef6bcdc9f1c8d5b4bf313bde48eba6afaf77294e5 /generic
parentcee1ce03b712770dc55c7c3b4b65c5026546d53f (diff)
parent6d6c732492789c16c16f822a7b3ae1421261b86d (diff)
downloadtcl-f21757bb59b183ee82e709542e8d741db5648e9a.zip
tcl-f21757bb59b183ee82e709542e8d741db5648e9a.tar.gz
tcl-f21757bb59b183ee82e709542e8d741db5648e9a.tar.bz2
3593703 Don't crash on bad input to Tcl_PkgRequire*().
Diffstat (limited to 'generic')
-rw-r--r--generic/tclPkg.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/generic/tclPkg.c b/generic/tclPkg.c
index 9b6e942..5b09ddb 100644
--- a/generic/tclPkg.c
+++ b/generic/tclPkg.c
@@ -356,6 +356,10 @@ PkgRequireCore(
char *script, *pkgVersionI;
Tcl_DString command;
+ if (TCL_OK != CheckAllRequirements(interp, reqc, reqv)) {
+ return NULL;
+ }
+
/*
* It can take up to three passes to find the package: one pass to run the
* "package unknown" script, one to run the "package ifneeded" script for