summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2016-07-02 17:57:58 (GMT)
committerdgp <dgp@users.sourceforge.net>2016-07-02 17:57:58 (GMT)
commit8694c5d2ef9e62f61322d3904c90edd7e550a290 (patch)
treeb4675f643ea62918c993582c56b16c6bdfc874ea /generic
parent725c3a636490b1c2afc7dfd48f4da92778104471 (diff)
parenta139661621ec842c91242c4b0fca910b9c964398 (diff)
downloadtcl-8694c5d2ef9e62f61322d3904c90edd7e550a290.zip
tcl-8694c5d2ef9e62f61322d3904c90edd7e550a290.tar.gz
tcl-8694c5d2ef9e62f61322d3904c90edd7e550a290.tar.bz2
[f961d7d1dd] Repair usage message for ensemble parameters with spaces.
Diffstat (limited to 'generic')
-rw-r--r--generic/tclEnsemble.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/generic/tclEnsemble.c b/generic/tclEnsemble.c
index 5c47ce3..a86b5c4 100644
--- a/generic/tclEnsemble.c
+++ b/generic/tclEnsemble.c
@@ -1674,18 +1674,11 @@ NsEnsembleImplementationCmdNR(
*/
Tcl_DString buf; /* Message being built */
- Tcl_Obj **elemPtrs; /* Parameter names */
- int len; /* Number of parameters to append */
Tcl_DStringInit(&buf);
- if (ensemblePtr->parameterList == NULL) {
- len = 0;
- } else if (TclListObjGetElements(NULL, ensemblePtr->parameterList,
- &len, &elemPtrs) != TCL_OK) {
- Tcl_Panic("List of ensemble parameters is not a list");
- }
- for (; len>0; len--,elemPtrs++) {
- TclDStringAppendObj(&buf, *elemPtrs);
+ if (ensemblePtr->parameterList) {
+ Tcl_DStringAppend(&buf,
+ TclGetString(ensemblePtr->parameterList), -1);
TclDStringAppendLiteral(&buf, " ");
}
TclDStringAppendLiteral(&buf, "subcommand ?arg ...?");