Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 451692 | Differences between
and this patch

Collapse All | Expand All

(-)gdb/gdbtk/generic/gdbtk.c.ORIG (-6 / +6 lines)
Lines 493-509 Link Here
493
  make_final_cleanup (gdbtk_cleanup, NULL);
493
  make_final_cleanup (gdbtk_cleanup, NULL);
494
494
495
  if (Tcl_Init (gdbtk_interp) != TCL_OK)
495
  if (Tcl_Init (gdbtk_interp) != TCL_OK)
496
    error ("Tcl_Init failed: %s", gdbtk_interp->result);
496
    error ("Tcl_Init failed: %s", Tcl_GetStringResult(gdbtk_interp));
497
497
498
  /* Initialize the Paths variable.  */
498
  /* Initialize the Paths variable.  */
499
  if (ide_initialize_paths (gdbtk_interp, "") != TCL_OK)
499
  if (ide_initialize_paths (gdbtk_interp, "") != TCL_OK)
500
    error ("ide_initialize_paths failed: %s", gdbtk_interp->result);
500
    error ("ide_initialize_paths failed: %s", Tcl_GetStringResult(gdbtk_interp));
501
501
502
  if (Tk_Init (gdbtk_interp) != TCL_OK)
502
  if (Tk_Init (gdbtk_interp) != TCL_OK)
503
    error ("Tk_Init failed: %s", gdbtk_interp->result);
503
    error ("Tk_Init failed: %s", Tcl_GetStringResult(gdbtk_interp));
504
504
505
  if (Tktable_Init (gdbtk_interp) != TCL_OK)
505
  if (Tktable_Init (gdbtk_interp) != TCL_OK)
506
    error ("Tktable_Init failed: %s", gdbtk_interp->result);
506
    error ("Tktable_Init failed: %s", Tcl_GetStringResult(gdbtk_interp));
507
507
508
  Tcl_StaticPackage (gdbtk_interp, "Tktable", Tktable_Init,
508
  Tcl_StaticPackage (gdbtk_interp, "Tktable", Tktable_Init,
509
		     (Tcl_PackageInitProc *) NULL);
509
		     (Tcl_PackageInitProc *) NULL);
Lines 559-565 Link Here
559
559
560
  if (Gdbtk_Init (gdbtk_interp) != TCL_OK)
560
  if (Gdbtk_Init (gdbtk_interp) != TCL_OK)
561
    {
561
    {
562
      error ("Gdbtk_Init failed: %s", gdbtk_interp->result);
562
      error ("Gdbtk_Init failed: %s", Tcl_GetStringResult(gdbtk_interp));
563
    }
563
    }
564
564
565
  Tcl_StaticPackage (gdbtk_interp, "Insight", Gdbtk_Init, NULL);
565
  Tcl_StaticPackage (gdbtk_interp, "Insight", Gdbtk_Init, NULL);
Lines 739-745 Link Here
739
739
740
  retval = Tcl_Eval (gdbtk_interp, cmd);
740
  retval = Tcl_Eval (gdbtk_interp, cmd);
741
741
742
  result = xstrdup (gdbtk_interp->result);
742
  result = xstrdup (Tcl_GetStringResult(gdbtk_interp));
743
743
744
  old_chain = make_cleanup (free, result);
744
  old_chain = make_cleanup (free, result);
745
745
(-)gdb/gdbtk/generic/gdbtk-hooks.c.ORIG (-6 / +6 lines)
Lines 255-267 Link Here
255
	  actual_len = 0;
255
	  actual_len = 0;
256
	}
256
	}
257
      else
257
      else
258
        actual_len = strlen (gdbtk_interp->result);
258
        actual_len = strlen (Tcl_GetStringResult(gdbtk_interp));
259
259
260
      /* Truncate the string if it is too big for the caller's buffer.  */
260
      /* Truncate the string if it is too big for the caller's buffer.  */
261
      if (actual_len >= sizeof_buf)
261
      if (actual_len >= sizeof_buf)
262
	actual_len = sizeof_buf - 1;
262
	actual_len = sizeof_buf - 1;
263
      
263
      
264
      memcpy (buf, gdbtk_interp->result, actual_len);
264
      memcpy (buf, Tcl_GetStringResult(gdbtk_interp), actual_len);
265
      buf[actual_len] = '\0';
265
      buf[actual_len] = '\0';
266
      return actual_len;
266
      return actual_len;
267
    }
267
    }
Lines 506-516 Link Here
506
506
507
  if (result == TCL_OK)
507
  if (result == TCL_OK)
508
    {
508
    {
509
      return (xstrdup (gdbtk_interp->result));
509
      return (xstrdup (Tcl_GetStringResult(gdbtk_interp)));
510
    }
510
    }
511
  else
511
  else
512
    {
512
    {
513
      gdbtk_fputs (gdbtk_interp->result, gdb_stdout);
513
      gdbtk_fputs (Tcl_GetStringResult(gdbtk_interp), gdb_stdout);
514
      gdbtk_fputs ("\n", gdb_stdout);
514
      gdbtk_fputs ("\n", gdb_stdout);
515
      return (NULL);
515
      return (NULL);
516
    }
516
    }
Lines 634-640 Link Here
634
    report_error ();
634
    report_error ();
635
  free(buf);
635
  free(buf);
636
636
637
  return atoi (gdbtk_interp->result);
637
  return atoi (Tcl_GetStringResult(gdbtk_interp));
638
}
638
}
639
639
640
640
Lines 687-693 Link Here
687
  gdbtk_two_elem_cmd ("gdbtk_tcl_query", buf);
687
  gdbtk_two_elem_cmd ("gdbtk_tcl_query", buf);
688
  free(buf);
688
  free(buf);
689
689
690
  val = atol (gdbtk_interp->result);
690
  val = atol (Tcl_GetStringResult(gdbtk_interp));
691
  return val;
691
  return val;
692
}
692
}
693
693
(-)gdb/gdbtk/plugins/rhabout/rhabout.c.ORIG (-1 / +1 lines)
Lines 22-28 Link Here
22
                Tcl_Interp *interp,
22
                Tcl_Interp *interp,
23
                int objc, Tcl_Obj *CONST objv[])
23
                int objc, Tcl_Obj *CONST objv[])
24
{
24
{
25
  interp->result = "\nThis is a sample plug-in\n";
25
  Tcl_SetResult(interp,"\nThis is a sample plug-in\n", TCL_VOLATILE);
26
  return TCL_OK;
26
  return TCL_OK;
27
}
27
}
28
28

Return to bug 451692