summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornijtmans <nijtmans>2009-04-27 09:41:49 (GMT)
committernijtmans <nijtmans>2009-04-27 09:41:49 (GMT)
commit51afb0f4ff1ba6723eb2b998a3134ea3a8fd7ed4 (patch)
tree6d83571d72ea4a51d0e9a6870ffdb8c2f9dc038d
parentb94498473df497ea4ba2958b6f1f16d7380100b1 (diff)
downloadtcl-51afb0f4ff1ba6723eb2b998a3134ea3a8fd7ed4.zip
tcl-51afb0f4ff1ba6723eb2b998a3134ea3a8fd7ed4.tar.gz
tcl-51afb0f4ff1ba6723eb2b998a3134ea3a8fd7ed4.tar.bz2
Reset internal INTERP_ALTERNATE_WRONG_ARGS
flag inside the Tcl_WrongNumArgs function, so the caller no longer has to do the reset.
-rw-r--r--ChangeLog6
-rw-r--r--generic/tclIOCmd.c4
-rw-r--r--generic/tclIndexObj.c3
3 files changed, 9 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index c7c7b97..1c976ed 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-04-27 Jan Nijtmans <nijtmans@users.sf.net>
+
+ * generic/tclIndexObj.c: Reset internal INTERP_ALTERNATE_WRONG_ARGS
+ * generic/tclIOCmd.c flag inside the Tcl_WrongNumArgs function,
+ so the caller no longer has to do the reset.
+
2009-04-24 Stuart Cassoff <stwo@users.sf.net>
* unix/Makefile.in: Don't chmod/exec installManPage.
diff --git a/generic/tclIOCmd.c b/generic/tclIOCmd.c
index 3ee768f..13a6853 100644
--- a/generic/tclIOCmd.c
+++ b/generic/tclIOCmd.c
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclIOCmd.c,v 1.63 2009/02/10 22:49:58 nijtmans Exp $
+ * RCS: @(#) $Id: tclIOCmd.c,v 1.64 2009/04/27 09:41:49 nijtmans Exp $
*/
#include "tclInt.h"
@@ -402,7 +402,6 @@ Tcl_ReadObjCmd(
iPtr->flags |= INTERP_ALTERNATE_WRONG_ARGS;
Tcl_WrongNumArgs(interp, 1, objv, "?-nonewline? channelId");
- iPtr->flags &= ~INTERP_ALTERNATE_WRONG_ARGS;
return TCL_ERROR;
}
@@ -1558,7 +1557,6 @@ Tcl_SocketObjCmd(
iPtr->flags |= INTERP_ALTERNATE_WRONG_ARGS;
Tcl_WrongNumArgs(interp, 1, objv,
"-server command ?-myaddr addr? port");
- iPtr->flags &= ~INTERP_ALTERNATE_WRONG_ARGS;
return TCL_ERROR;
}
diff --git a/generic/tclIndexObj.c b/generic/tclIndexObj.c
index 6edd577..bbdae95 100644
--- a/generic/tclIndexObj.c
+++ b/generic/tclIndexObj.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclIndexObj.c,v 1.50 2009/02/10 22:49:49 nijtmans Exp $
+ * RCS: @(#) $Id: tclIndexObj.c,v 1.51 2009/04/27 09:41:49 nijtmans Exp $
*/
#include "tclInt.h"
@@ -886,6 +886,7 @@ Tcl_WrongNumArgs(
TclNewObj(objPtr);
if (iPtr->flags & INTERP_ALTERNATE_WRONG_ARGS) {
+ iPtr->flags &= ~INTERP_ALTERNATE_WRONG_ARGS;
Tcl_AppendObjToObj(objPtr, Tcl_GetObjResult(interp));
Tcl_AppendToObj(objPtr, " or \"", -1);
} else {