f90f47a0f2
with lots of testing by sthen@
58 lines
2.3 KiB
Plaintext
58 lines
2.3 KiB
Plaintext
$OpenBSD: patch-tcl_tcl_compat_c,v 1.3 2007/10/26 14:06:02 steven Exp $
|
|
--- tcl/tcl_compat.c.orig Thu May 17 17:15:54 2007
|
|
+++ tcl/tcl_compat.c Sat Sep 15 12:39:56 2007
|
|
@@ -60,7 +60,7 @@ bdb_HCommand(interp, objc, objv)
|
|
* in the 'berkdb' command.
|
|
*/
|
|
if (Tcl_GetIndexFromObj(interp,
|
|
- objv[1], hcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
+ objv[1], (CONST84 char **)hcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
return (IS_HELP(objv[1]));
|
|
|
|
res = NULL;
|
|
@@ -91,7 +91,7 @@ bdb_HCommand(interp, objc, objv)
|
|
}
|
|
item.key = Tcl_GetStringFromObj(objv[2], NULL);
|
|
item.data = Tcl_GetStringFromObj(objv[3], NULL);
|
|
- if (Tcl_GetIndexFromObj(interp, objv[4], srchacts,
|
|
+ if (Tcl_GetIndexFromObj(interp, objv[4], (CONST84 char **)srchacts,
|
|
"action", TCL_EXACT, &actindex) != TCL_OK)
|
|
return (IS_HELP(objv[4]));
|
|
switch ((enum srchacts)actindex) {
|
|
@@ -185,7 +185,7 @@ bdb_NdbmOpen(interp, objc, objv, dbpp)
|
|
*/
|
|
i = 2;
|
|
while (i < objc) {
|
|
- if (Tcl_GetIndexFromObj(interp, objv[i], ndbopen, "option",
|
|
+ if (Tcl_GetIndexFromObj(interp, objv[i], (CONST84 char **)ndbopen, "option",
|
|
TCL_EXACT, &optindex) != TCL_OK) {
|
|
arg = Tcl_GetStringFromObj(objv[i], NULL);
|
|
if (arg[0] == '-') {
|
|
@@ -336,7 +336,7 @@ bdb_DbmCommand(interp, objc, objv, flag, dbm)
|
|
* in the 'berkdb' command.
|
|
*/
|
|
if (Tcl_GetIndexFromObj(interp,
|
|
- objv[1], dbmcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
+ objv[1], (CONST84 char **)dbmcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
return (IS_HELP(objv[1]));
|
|
|
|
switch ((enum dbmcmds)cmdindex) {
|
|
@@ -445,7 +445,7 @@ bdb_DbmCommand(interp, objc, objv, flag, dbm)
|
|
if (flag == DBTCL_DBM)
|
|
ret = store(key, data);
|
|
else if (flag == DBTCL_NDBM) {
|
|
- if (Tcl_GetIndexFromObj(interp, objv[4], stflag,
|
|
+ if (Tcl_GetIndexFromObj(interp, objv[4], (CONST84 char **)stflag,
|
|
"flag", TCL_EXACT, &stindex) != TCL_OK)
|
|
return (IS_HELP(objv[4]));
|
|
switch ((enum stflag)stindex) {
|
|
@@ -636,7 +636,7 @@ ndbm_Cmd(clientData, interp, objc, objv)
|
|
* defined above.
|
|
*/
|
|
if (Tcl_GetIndexFromObj(interp,
|
|
- objv[1], ndbcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
+ objv[1], (CONST84 char **)ndbcmds, "command", TCL_EXACT, &cmdindex) != TCL_OK)
|
|
return (IS_HELP(objv[1]));
|
|
|
|
res = NULL;
|