mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-07-28 04:13:28 +08:00
Fri Aug 28 12:14:49 1998 Martin M. Hunt <hunt@cygnus.com>
* gdbtk-cmds.c (gdb_loadfile): Open the file after doing the symtab lookup and calling symtab_to_filename(). This makes GDBtk work with the GDB "dir" command.
This commit is contained in:
@ -1,3 +1,9 @@
|
|||||||
|
Fri Aug 28 12:14:49 1998 Martin M. Hunt <hunt@cygnus.com>
|
||||||
|
|
||||||
|
* gdbtk-cmds.c (gdb_loadfile): Open the file after doing
|
||||||
|
the symtab lookup and calling symtab_to_filename(). This
|
||||||
|
makes GDBtk work with the GDB "dir" command.
|
||||||
|
|
||||||
1998-08-18 Keith Seitz <keiths@cygnus.com>
|
1998-08-18 Keith Seitz <keiths@cygnus.com>
|
||||||
|
|
||||||
* gdbtk-hooks.c (gdbtk_add_hooks): Set selected_frame_level_changed_hook.
|
* gdbtk-hooks.c (gdbtk_add_hooks): Set selected_frame_level_changed_hook.
|
||||||
|
@ -2581,12 +2581,6 @@ gdb_loadfile (clientData, interp, objc, objv)
|
|||||||
file = Tcl_GetStringFromObj (objv[2], NULL);
|
file = Tcl_GetStringFromObj (objv[2], NULL);
|
||||||
Tcl_GetBooleanFromObj (interp, objv[3], &linenumbers);
|
Tcl_GetBooleanFromObj (interp, objv[3], &linenumbers);
|
||||||
|
|
||||||
if ((fp = fopen ( file, "r" )) == NULL)
|
|
||||||
{
|
|
||||||
Tcl_SetStringObj ( result_ptr->obj_ptr, "Can't open file for reading", -1);
|
|
||||||
return TCL_ERROR;
|
|
||||||
}
|
|
||||||
|
|
||||||
symtab = full_lookup_symtab (file);
|
symtab = full_lookup_symtab (file);
|
||||||
if (!symtab)
|
if (!symtab)
|
||||||
{
|
{
|
||||||
@ -2595,6 +2589,13 @@ gdb_loadfile (clientData, interp, objc, objv)
|
|||||||
return TCL_ERROR;
|
return TCL_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
file = symtab_to_filename ( symtab );
|
||||||
|
if ((fp = fopen ( file, "r" )) == NULL)
|
||||||
|
{
|
||||||
|
Tcl_SetStringObj ( result_ptr->obj_ptr, "Can't open file for reading", -1);
|
||||||
|
return TCL_ERROR;
|
||||||
|
}
|
||||||
|
|
||||||
if (stat (file, &st) < 0)
|
if (stat (file, &st) < 0)
|
||||||
{
|
{
|
||||||
catch_errors (perror_with_name_wrapper, "gdbtk: get time stamp", "",
|
catch_errors (perror_with_name_wrapper, "gdbtk: get time stamp", "",
|
||||||
|
Reference in New Issue
Block a user