From mboxrd@z Thu Jan 1 00:00:00 1970 From: Keith Seitz To: Insight Maling List Cc: Ian Roxborough Subject: [PATCH] Tcl cleanups from Ian Date: Thu, 16 Aug 2001 08:48:00 -0000 Message-id: X-SW-Source: 2001-q3/msg00143.html Hi, I've committed the following patch to the repository. My thanks to Ian for looking into this nightmare. Keith ChangeLog 2001-08-16 Keith Seitz From Ian Roxborough * generic/gdbtk-hooks.c (x_event): Deal with Tcl API insanity for Tcl_ObjGetVar2 or Tcl_GetObjVar2. (gdbtk_trace_find): Likewise for Tcl_GlobalEvalObj or Tcl_EvalObj (TCL_EVAL_GLOBAL). Patch Index: generic/gdbtk-hooks.c =================================================================== RCS file: /cvs/src/src/gdb/gdbtk/generic/gdbtk-hooks.c,v retrieving revision 1.17 diff -u -p -r1.17 gdbtk-hooks.c --- gdbtk-hooks.c 2001/08/13 18:30:36 1.17 +++ gdbtk-hooks.c 2001/08/16 15:17:59 @@ -462,7 +462,7 @@ x_event (signo) int val; if (varname == NULL) { -#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 1 +#if TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION < 1 || TCL_MINOR_VERSION > 2) Tcl_Obj *varnamestrobj = Tcl_NewStringObj ("download_cancel_ok", -1); varname = Tcl_ObjGetVar2 (gdbtk_interp, varnamestrobj, NULL, TCL_GLOBAL_ONLY); #else @@ -733,7 +733,7 @@ gdbtk_trace_find (arg, from_tty) Tcl_NewStringObj ("gdbtk_tcl_trace_find_hook", -1)); Tcl_ListObjAppendElement (gdbtk_interp, cmdObj, Tcl_NewStringObj (arg, -1)); Tcl_ListObjAppendElement (gdbtk_interp, cmdObj, Tcl_NewIntObj (from_tty)); -#if TCL_MAJOR_VERSION == 8 && TCL_MINOR_VERSION < 1 +#if TCL_MAJOR_VERSION == 8 && (TCL_MINOR_VERSION < 1 || TCL_MINOR_VERSION > 2) if (Tcl_GlobalEvalObj (gdbtk_interp, cmdObj) != TCL_OK) report_error (); #else