- Upgrade to GDB 6.7. Drop redundant patches, forward-port remaining ones.
- Fix rereading of the main executable on its change.
This commit is contained in:
parent
cc171577b7
commit
eb9d945afa
55 changed files with 1702 additions and 7915 deletions
|
|
@ -1,194 +1,38 @@
|
|||
Index: gdb-6.6/gdb/mi/mi-cmd-env.c
|
||||
[base]
|
||||
|
||||
2007-10-14 Jan Kratochvil <jan.kratochvil@redhat.com>
|
||||
|
||||
Port to GDB-6.7.
|
||||
|
||||
Index: gdb-6.7/gdb/mi/mi-cmd-env.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/mi/mi-cmd-env.c
|
||||
+++ gdb-6.6/gdb/mi/mi-cmd-env.c
|
||||
@@ -126,7 +126,7 @@ mi_cmd_env_path (char *command, char **a
|
||||
static struct mi_opt opts[] =
|
||||
{
|
||||
{"r", RESET_OPT, 0},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
--- gdb-6.7.orig/gdb/mi/mi-cmd-env.c 2007-10-14 23:42:39.000000000 +0200
|
||||
+++ gdb-6.7/gdb/mi/mi-cmd-env.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -78,7 +78,8 @@ mi_cmd_env_pwd (char *command, char **ar
|
||||
|
||||
/* Otherwise the mi level is 2 or higher. */
|
||||
|
||||
dont_repeat ();
|
||||
@@ -198,7 +198,7 @@ mi_cmd_env_dir (char *command, char **ar
|
||||
static struct mi_opt opts[] =
|
||||
{
|
||||
{"r", RESET_OPT, 0},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
- getcwd (gdb_dirbuf, sizeof (gdb_dirbuf));
|
||||
+ /* Unused result. */
|
||||
+ 1 && getcwd (gdb_dirbuf, sizeof (gdb_dirbuf));
|
||||
ui_out_field_string (uiout, "cwd", gdb_dirbuf);
|
||||
|
||||
dont_repeat ();
|
||||
Index: gdb-6.6/gdb/mi/mi-getopt.c
|
||||
return MI_CMD_DONE;
|
||||
Index: gdb-6.7/gdb/testsuite/gdb.base/move-dir.h
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/mi/mi-getopt.c
|
||||
+++ gdb-6.6/gdb/mi/mi-getopt.c
|
||||
@@ -82,7 +82,7 @@ mi_valid_noargs (const char *prefix, int
|
||||
char *optarg;
|
||||
static struct mi_opt opts[] =
|
||||
{
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
if (mi_getopt (prefix, argc, argv, opts, &optind, &optarg) == -1)
|
||||
Index: gdb-6.6/gdb/mi/mi-cmd-break.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/mi/mi-cmd-break.c
|
||||
+++ gdb-6.6/gdb/mi/mi-cmd-break.c
|
||||
@@ -90,7 +90,7 @@ mi_cmd_break_insert (char *command, char
|
||||
{"c", CONDITION_OPT, 1},
|
||||
{"i", IGNORE_COUNT_OPT, 1},
|
||||
{"p", THREAD_OPT, 1},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
/* Parse arguments. It could be -r or -h or -t, <location> or ``--''
|
||||
@@ -196,7 +196,7 @@ mi_cmd_break_watch (char *command, char
|
||||
{
|
||||
{"r", READ_OPT, 0},
|
||||
{"a", ACCESS_OPT, 0},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
/* Parse arguments. */
|
||||
Index: gdb-6.6/gdb/mi/mi-cmd-disas.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/mi/mi-cmd-disas.c
|
||||
+++ gdb-6.6/gdb/mi/mi-cmd-disas.c
|
||||
@@ -84,7 +84,7 @@ mi_cmd_disassemble (char *command, char
|
||||
{"n", NUM_OPT, 1},
|
||||
{"s", START_OPT, 1},
|
||||
{"e", END_OPT, 1},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
/* Get the options with their arguments. Keep track of what we
|
||||
Index: gdb-6.6/gdb/mi/mi-main.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/mi/mi-main.c
|
||||
+++ gdb-6.6/gdb/mi/mi-main.c
|
||||
@@ -773,7 +773,7 @@ mi_cmd_data_read_memory (char *command,
|
||||
static struct mi_opt opts[] =
|
||||
{
|
||||
{"o", OFFSET_OPT, 1},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
while (1)
|
||||
@@ -973,7 +973,7 @@ mi_cmd_data_write_memory (char *command,
|
||||
static struct mi_opt opts[] =
|
||||
{
|
||||
{"o", OFFSET_OPT, 1},
|
||||
- 0
|
||||
+ {0}
|
||||
};
|
||||
|
||||
while (1)
|
||||
Index: gdb-6.6/gdb/p-valprint.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/p-valprint.c
|
||||
+++ gdb-6.6/gdb/p-valprint.c
|
||||
@@ -753,7 +753,7 @@ pascal_object_print_value_fields (struct
|
||||
int dont_print_statmem)
|
||||
{
|
||||
int i, len, n_baseclasses;
|
||||
- struct obstack tmp_obstack;
|
||||
+ struct obstack tmp_obstack = {0};
|
||||
char *last_dont_print = obstack_next_free (&dont_print_statmem_obstack);
|
||||
|
||||
CHECK_TYPEDEF (type);
|
||||
@@ -922,7 +922,7 @@ pascal_object_print_value (struct type *
|
||||
enum val_prettyprint pretty,
|
||||
struct type **dont_print_vb)
|
||||
{
|
||||
- struct obstack tmp_obstack;
|
||||
+ struct obstack tmp_obstack = {0};
|
||||
struct type **last_dont_print
|
||||
= (struct type **) obstack_next_free (&dont_print_vb_obstack);
|
||||
int i, n_baseclasses = TYPE_N_BASECLASSES (type);
|
||||
Index: gdb-6.6/gdb/cp-valprint.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/cp-valprint.c
|
||||
+++ gdb-6.6/gdb/cp-valprint.c
|
||||
@@ -265,7 +265,7 @@ cp_print_value_fields (struct type *type
|
||||
struct type **dont_print_vb,int dont_print_statmem)
|
||||
{
|
||||
int i, len, n_baseclasses;
|
||||
- struct obstack tmp_obstack;
|
||||
+ struct obstack tmp_obstack = {0};
|
||||
char *last_dont_print = obstack_next_free (&dont_print_statmem_obstack);
|
||||
int fields_seen = 0;
|
||||
|
||||
@@ -524,7 +524,7 @@ cp_print_value (struct type *type, struc
|
||||
struct ui_file *stream, int format, int recurse,
|
||||
enum val_prettyprint pretty, struct type **dont_print_vb)
|
||||
{
|
||||
- struct obstack tmp_obstack;
|
||||
+ struct obstack tmp_obstack = {0};
|
||||
struct type **last_dont_print
|
||||
= (struct type **) obstack_next_free (&dont_print_vb_obstack);
|
||||
int i, n_baseclasses = TYPE_N_BASECLASSES (type);
|
||||
Index: gdb-6.6/gdb/tui/tui-layout.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/tui/tui-layout.c
|
||||
+++ gdb-6.6/gdb/tui/tui-layout.c
|
||||
@@ -755,7 +755,7 @@ show_source_disasm_command (void)
|
||||
if (TUI_DISASM_WIN == NULL)
|
||||
{
|
||||
make_disasm_window (&TUI_DISASM_WIN, asm_height, src_height - 1);
|
||||
- init_and_make_win ((void **) & locator,
|
||||
+ init_and_make_win ((void **)(char *) & locator,
|
||||
LOCATOR_WIN,
|
||||
2 /* 1 */ ,
|
||||
tui_term_width (),
|
||||
@@ -848,7 +848,7 @@ show_data (enum tui_layout_type new_layo
|
||||
make_source_window (&tui_win_list[win_type], src_height, data_height - 1);
|
||||
else
|
||||
make_disasm_window (&tui_win_list[win_type], src_height, data_height - 1);
|
||||
- init_and_make_win ((void **) & locator,
|
||||
+ init_and_make_win ((void **)(char *) & locator,
|
||||
LOCATOR_WIN,
|
||||
2 /* 1 */ ,
|
||||
tui_term_width (),
|
||||
@@ -963,7 +963,7 @@ make_source_or_disasm_window (struct tui
|
||||
execution_info = tui_source_exec_info_win_ptr ();
|
||||
else
|
||||
execution_info = tui_disassem_exec_info_win_ptr ();
|
||||
- init_and_make_win ((void **) & execution_info,
|
||||
+ init_and_make_win ((void **)(char *) & execution_info,
|
||||
EXEC_INFO_WIN,
|
||||
height,
|
||||
3,
|
||||
@@ -1013,7 +1013,7 @@ show_source_or_disasm_and_command (enum
|
||||
make_source_window (win_info_ptr, src_height - 1, 0);
|
||||
else
|
||||
make_disasm_window (win_info_ptr, src_height - 1, 0);
|
||||
- init_and_make_win ((void **) & locator,
|
||||
+ init_and_make_win ((void **)(char *) & locator,
|
||||
LOCATOR_WIN,
|
||||
2 /* 1 */ ,
|
||||
tui_term_width (),
|
||||
Index: gdb-6.6/gdb/testsuite/gdb.base/move-dir.h
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/testsuite/gdb.base/move-dir.h
|
||||
+++ gdb-6.6/gdb/testsuite/gdb.base/move-dir.h
|
||||
--- gdb-6.7.orig/gdb/testsuite/gdb.base/move-dir.h 2007-10-14 23:31:22.000000000 +0200
|
||||
+++ gdb-6.7/gdb/testsuite/gdb.base/move-dir.h 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -1,4 +1,4 @@
|
||||
-#include <stdlib.h>
|
||||
+#include <stdio.h>
|
||||
|
||||
void other() {
|
||||
const char* ostring = "other";
|
||||
Index: gdb-6.6/gdb/testsuite/gdb.base/sigrepeat.c
|
||||
Index: gdb-6.7/gdb/testsuite/gdb.base/sigrepeat.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/testsuite/gdb.base/sigrepeat.c
|
||||
+++ gdb-6.6/gdb/testsuite/gdb.base/sigrepeat.c
|
||||
@@ -22,6 +22,7 @@
|
||||
--- gdb-6.7.orig/gdb/testsuite/gdb.base/sigrepeat.c 2007-08-23 20:08:49.000000000 +0200
|
||||
+++ gdb-6.7/gdb/testsuite/gdb.base/sigrepeat.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -21,6 +21,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <signal.h>
|
||||
|
|
@ -196,11 +40,11 @@ Index: gdb-6.6/gdb/testsuite/gdb.base/sigrepeat.c
|
|||
#include <sys/time.h>
|
||||
|
||||
static volatile int done[2];
|
||||
Index: gdb-6.6/gdb/s390-tdep.c
|
||||
Index: gdb-6.7/gdb/s390-tdep.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/s390-tdep.c
|
||||
+++ gdb-6.6/gdb/s390-tdep.c
|
||||
@@ -2277,6 +2277,9 @@ s390_return_value (struct gdbarch *gdbar
|
||||
--- gdb-6.7.orig/gdb/s390-tdep.c 2007-10-02 21:26:42.000000000 +0200
|
||||
+++ gdb-6.7/gdb/s390-tdep.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -2214,6 +2214,9 @@ s390_return_value (struct gdbarch *gdbar
|
||||
case RETURN_VALUE_STRUCT_CONVENTION:
|
||||
error (_("Cannot set function return value."));
|
||||
break;
|
||||
|
|
@ -210,7 +54,7 @@ Index: gdb-6.6/gdb/s390-tdep.c
|
|||
}
|
||||
}
|
||||
else if (out)
|
||||
@@ -2309,6 +2312,9 @@ s390_return_value (struct gdbarch *gdbar
|
||||
@@ -2246,6 +2249,9 @@ s390_return_value (struct gdbarch *gdbar
|
||||
case RETURN_VALUE_STRUCT_CONVENTION:
|
||||
error (_("Function return value unknown."));
|
||||
break;
|
||||
|
|
@ -220,27 +64,10 @@ Index: gdb-6.6/gdb/s390-tdep.c
|
|||
}
|
||||
}
|
||||
|
||||
Index: gdb-6.6/gdb/remote.c
|
||||
Index: gdb-6.7/gdb/f-exp.y
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/remote.c
|
||||
+++ gdb-6.6/gdb/remote.c
|
||||
@@ -2843,10 +2843,10 @@ cleanup_sigint_signal_handler (void *dum
|
||||
{
|
||||
signal (SIGINT, handle_sigint);
|
||||
if (sigint_remote_twice_token)
|
||||
- delete_async_signal_handler ((struct async_signal_handler **)
|
||||
+ delete_async_signal_handler ((struct async_signal_handler **) (char *)
|
||||
&sigint_remote_twice_token);
|
||||
if (sigint_remote_token)
|
||||
- delete_async_signal_handler ((struct async_signal_handler **)
|
||||
+ delete_async_signal_handler ((struct async_signal_handler **) (char *)
|
||||
&sigint_remote_token);
|
||||
}
|
||||
|
||||
Index: gdb-6.6/gdb/f-exp.y
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/f-exp.y
|
||||
+++ gdb-6.6/gdb/f-exp.y
|
||||
--- gdb-6.7.orig/gdb/f-exp.y 2007-06-12 17:33:03.000000000 +0200
|
||||
+++ gdb-6.7/gdb/f-exp.y 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -567,6 +567,8 @@ ptype : typebase
|
||||
case tp_function:
|
||||
follow_type = lookup_function_type (follow_type);
|
||||
|
|
@ -250,48 +77,11 @@ Index: gdb-6.6/gdb/f-exp.y
|
|||
}
|
||||
$$ = follow_type;
|
||||
}
|
||||
Index: gdb-6.6/gdb/remote-fileio.c
|
||||
Index: gdb-6.7/gdb/source.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/remote-fileio.c
|
||||
+++ gdb-6.6/gdb/remote-fileio.c
|
||||
@@ -1332,19 +1332,19 @@ static struct {
|
||||
char *name;
|
||||
void (*func)(char *);
|
||||
} remote_fio_func_map[] = {
|
||||
- "open", remote_fileio_func_open,
|
||||
- "close", remote_fileio_func_close,
|
||||
- "read", remote_fileio_func_read,
|
||||
- "write", remote_fileio_func_write,
|
||||
- "lseek", remote_fileio_func_lseek,
|
||||
- "rename", remote_fileio_func_rename,
|
||||
- "unlink", remote_fileio_func_unlink,
|
||||
- "stat", remote_fileio_func_stat,
|
||||
- "fstat", remote_fileio_func_fstat,
|
||||
- "gettimeofday", remote_fileio_func_gettimeofday,
|
||||
- "isatty", remote_fileio_func_isatty,
|
||||
- "system", remote_fileio_func_system,
|
||||
- NULL, NULL
|
||||
+ {"open", remote_fileio_func_open},
|
||||
+ {"close", remote_fileio_func_close},
|
||||
+ {"read", remote_fileio_func_read},
|
||||
+ {"write", remote_fileio_func_write},
|
||||
+ {"lseek", remote_fileio_func_lseek},
|
||||
+ {"rename", remote_fileio_func_rename},
|
||||
+ {"unlink", remote_fileio_func_unlink},
|
||||
+ {"stat", remote_fileio_func_stat},
|
||||
+ {"fstat", remote_fileio_func_fstat},
|
||||
+ {"gettimeofday", remote_fileio_func_gettimeofday},
|
||||
+ {"isatty", remote_fileio_func_isatty},
|
||||
+ {"system", remote_fileio_func_system},
|
||||
+ {NULL, NULL}
|
||||
};
|
||||
|
||||
static int
|
||||
Index: gdb-6.6/gdb/source.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/source.c
|
||||
+++ gdb-6.6/gdb/source.c
|
||||
@@ -172,7 +172,7 @@ get_current_source_symtab_and_line (void
|
||||
--- gdb-6.7.orig/gdb/source.c 2007-08-23 20:08:38.000000000 +0200
|
||||
+++ gdb-6.7/gdb/source.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -170,7 +170,7 @@ get_current_source_symtab_and_line (void
|
||||
void
|
||||
set_default_source_symtab_and_line (void)
|
||||
{
|
||||
|
|
@ -300,7 +90,7 @@ Index: gdb-6.6/gdb/source.c
|
|||
|
||||
if (!have_full_symbols () && !have_partial_symbols ())
|
||||
error (_("No symbol table is loaded. Use the \"file\" command."));
|
||||
@@ -1428,7 +1428,7 @@ static void
|
||||
@@ -1439,7 +1439,7 @@ static void
|
||||
line_info (char *arg, int from_tty)
|
||||
{
|
||||
struct symtabs_and_lines sals;
|
||||
|
|
@ -309,92 +99,24 @@ Index: gdb-6.6/gdb/source.c
|
|||
CORE_ADDR start_pc, end_pc;
|
||||
int i;
|
||||
|
||||
Index: gdb-6.6/gdb/symfile.c
|
||||
Index: gdb-6.7/gdb/linespec.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/symfile.c
|
||||
+++ gdb-6.6/gdb/symfile.c
|
||||
@@ -2933,6 +2933,8 @@ add_psymbol_with_dem_name_to_list (char
|
||||
deprecated_bcache (buf, dem_namelength + 1, objfile->psymbol_cache);
|
||||
break;
|
||||
/* FIXME What should be done for the default case? Ignoring for now. */
|
||||
+ default:
|
||||
+ break;
|
||||
}
|
||||
|
||||
/* val and coreaddr are mutually exclusive, one of them *will* be zero */
|
||||
Index: gdb-6.6/gdb/linespec.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/linespec.c
|
||||
+++ gdb-6.6/gdb/linespec.c
|
||||
@@ -1631,7 +1631,7 @@ static struct symtabs_and_lines
|
||||
--- gdb-6.7.orig/gdb/linespec.c 2007-10-14 23:31:03.000000000 +0200
|
||||
+++ gdb-6.7/gdb/linespec.c 2007-10-14 23:53:57.000000000 +0200
|
||||
@@ -1654,7 +1654,7 @@ static struct symtabs_and_lines
|
||||
find_method (int funfirstline, char ***canonical, char *saved_arg,
|
||||
char *copy, struct type *t, struct symbol *sym_class)
|
||||
{
|
||||
- struct symtabs_and_lines values;
|
||||
+ struct symtabs_and_lines values = {0};
|
||||
struct symbol *sym = 0;
|
||||
+ struct symtabs_and_lines values = { NULL };
|
||||
struct symbol *sym = NULL;
|
||||
int i1; /* Counter for the symbol array. */
|
||||
struct symbol **sym_arr = alloca (total_number_of_methods (t)
|
||||
Index: gdb-6.6/gdb/macroscope.c
|
||||
Index: gdb-6.7/gdb/gdb-events.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/macroscope.c
|
||||
+++ gdb-6.6/gdb/macroscope.c
|
||||
@@ -33,7 +33,7 @@
|
||||
struct macro_scope *
|
||||
sal_macro_scope (struct symtab_and_line sal)
|
||||
{
|
||||
- struct macro_source_file *main, *inclusion;
|
||||
+ struct macro_source_file *main_sf, *inclusion;
|
||||
struct macro_scope *ms;
|
||||
|
||||
if (! sal.symtab
|
||||
@@ -42,8 +42,8 @@ sal_macro_scope (struct symtab_and_line
|
||||
|
||||
ms = (struct macro_scope *) xmalloc (sizeof (*ms));
|
||||
|
||||
- main = macro_main (sal.symtab->macro_table);
|
||||
- inclusion = macro_lookup_inclusion (main, sal.symtab->filename);
|
||||
+ main_sf = macro_main (sal.symtab->macro_table);
|
||||
+ inclusion = macro_lookup_inclusion (main_sf, sal.symtab->filename);
|
||||
|
||||
if (inclusion)
|
||||
{
|
||||
@@ -66,7 +66,7 @@ sal_macro_scope (struct symtab_and_line
|
||||
|
||||
For the time being, though, we'll just treat these as
|
||||
occurring at the end of the main source file. */
|
||||
- ms->file = main;
|
||||
+ ms->file = main_sf;
|
||||
ms->line = -1;
|
||||
|
||||
complaint (&symfile_complaints,
|
||||
@@ -83,7 +83,6 @@ struct macro_scope *
|
||||
default_macro_scope (void)
|
||||
{
|
||||
struct symtab_and_line sal;
|
||||
- struct macro_source_file *main;
|
||||
struct macro_scope *ms;
|
||||
|
||||
/* If there's a selected frame, use its PC. */
|
||||
Index: gdb-6.6/gdb/target.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/target.c
|
||||
+++ gdb-6.6/gdb/target.c
|
||||
@@ -1045,6 +1045,9 @@ memory_xfer_partial (struct target_ops *
|
||||
if (writebuf != NULL)
|
||||
error (_("Writing to flash memory forbidden in this context"));
|
||||
break;
|
||||
+
|
||||
+ default:
|
||||
+ break;
|
||||
}
|
||||
|
||||
if (region->attrib.cache)
|
||||
Index: gdb-6.6/gdb/gdb-events.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/gdb-events.c
|
||||
+++ gdb-6.6/gdb/gdb-events.c
|
||||
@@ -321,6 +321,8 @@ gdb_events_deliver (struct gdb_events *v
|
||||
--- gdb-6.7.orig/gdb/gdb-events.c 2007-08-23 20:08:31.000000000 +0200
|
||||
+++ gdb-6.7/gdb/gdb-events.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -319,6 +319,8 @@ gdb_events_deliver (struct gdb_events *v
|
||||
case architecture_changed:
|
||||
vector->architecture_changed ();
|
||||
break;
|
||||
|
|
@ -403,11 +125,11 @@ Index: gdb-6.6/gdb/gdb-events.c
|
|||
}
|
||||
delivering_events = event->next;
|
||||
xfree (event);
|
||||
Index: gdb-6.6/gdb/dwarf2read.c
|
||||
Index: gdb-6.7/gdb/dwarf2read.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/dwarf2read.c
|
||||
+++ gdb-6.6/gdb/dwarf2read.c
|
||||
@@ -9307,6 +9307,7 @@ dwarf_decode_macros (struct line_header
|
||||
--- gdb-6.7.orig/gdb/dwarf2read.c 2007-10-14 23:31:22.000000000 +0200
|
||||
+++ gdb-6.7/gdb/dwarf2read.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -9585,6 +9585,7 @@ dwarf_decode_macros (struct line_header
|
||||
for (;;)
|
||||
{
|
||||
enum dwarf_macinfo_record_type macinfo_type;
|
||||
|
|
@ -415,7 +137,7 @@ Index: gdb-6.6/gdb/dwarf2read.c
|
|||
|
||||
/* Do we at least have room for a macinfo type byte? */
|
||||
if (mac_ptr >= mac_end)
|
||||
@@ -9318,13 +9319,16 @@ dwarf_decode_macros (struct line_header
|
||||
@@ -9596,13 +9597,16 @@ dwarf_decode_macros (struct line_header
|
||||
macinfo_type = read_1_byte (abfd, mac_ptr);
|
||||
mac_ptr++;
|
||||
|
||||
|
|
@ -437,11 +159,11 @@ Index: gdb-6.6/gdb/dwarf2read.c
|
|||
case DW_MACINFO_define:
|
||||
case DW_MACINFO_undef:
|
||||
{
|
||||
Index: gdb-6.6/gdb/stabsread.c
|
||||
Index: gdb-6.7/gdb/stabsread.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/stabsread.c
|
||||
+++ gdb-6.6/gdb/stabsread.c
|
||||
@@ -1794,7 +1794,8 @@ again:
|
||||
--- gdb-6.7.orig/gdb/stabsread.c 2007-10-09 00:44:32.000000000 +0200
|
||||
+++ gdb-6.7/gdb/stabsread.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -1842,7 +1842,8 @@ again:
|
||||
struct type *domain = read_type (pp, objfile);
|
||||
struct type *return_type;
|
||||
struct field *args;
|
||||
|
|
@ -451,11 +173,11 @@ Index: gdb-6.6/gdb/stabsread.c
|
|||
|
||||
if (**pp != ',')
|
||||
/* Invalid member type data format. */
|
||||
Index: gdb-6.6/gdb/dwarf2expr.c
|
||||
Index: gdb-6.7/gdb/dwarf2expr.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/dwarf2expr.c
|
||||
+++ gdb-6.6/gdb/dwarf2expr.c
|
||||
@@ -559,6 +559,8 @@ execute_stack_op (struct dwarf_expr_cont
|
||||
--- gdb-6.7.orig/gdb/dwarf2expr.c 2007-08-23 20:08:28.000000000 +0200
|
||||
+++ gdb-6.7/gdb/dwarf2expr.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -594,6 +594,8 @@ execute_stack_op (struct dwarf_expr_cont
|
||||
op_ptr = read_uleb128 (op_ptr, op_end, ®);
|
||||
result += reg;
|
||||
break;
|
||||
|
|
@ -464,24 +186,11 @@ Index: gdb-6.6/gdb/dwarf2expr.c
|
|||
}
|
||||
break;
|
||||
|
||||
Index: gdb-6.6/gdb/varobj.c
|
||||
Index: gdb-6.7/gdb/varobj.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/varobj.c
|
||||
+++ gdb-6.6/gdb/varobj.c
|
||||
@@ -325,10 +325,9 @@ struct language_specific
|
||||
|
||||
/* Array of known source language routines. */
|
||||
static struct language_specific
|
||||
- languages[vlang_end][sizeof (struct language_specific)] = {
|
||||
+ languages[vlang_end] = {
|
||||
/* Unknown (try treating as C */
|
||||
- {
|
||||
- vlang_unknown,
|
||||
+ {vlang_unknown,
|
||||
c_number_of_children,
|
||||
c_name_of_variable,
|
||||
c_name_of_child,
|
||||
@@ -339,8 +338,7 @@ static struct language_specific
|
||||
--- gdb-6.7.orig/gdb/varobj.c 2007-10-13 05:29:58.000000000 +0200
|
||||
+++ gdb-6.7/gdb/varobj.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -347,8 +347,7 @@ static struct language_specific language
|
||||
c_value_of_variable}
|
||||
,
|
||||
/* C */
|
||||
|
|
@ -491,7 +200,7 @@ Index: gdb-6.6/gdb/varobj.c
|
|||
c_number_of_children,
|
||||
c_name_of_variable,
|
||||
c_name_of_child,
|
||||
@@ -351,8 +349,7 @@ static struct language_specific
|
||||
@@ -360,8 +359,7 @@ static struct language_specific language
|
||||
c_value_of_variable}
|
||||
,
|
||||
/* C++ */
|
||||
|
|
@ -501,7 +210,7 @@ Index: gdb-6.6/gdb/varobj.c
|
|||
cplus_number_of_children,
|
||||
cplus_name_of_variable,
|
||||
cplus_name_of_child,
|
||||
@@ -363,8 +360,7 @@ static struct language_specific
|
||||
@@ -373,8 +371,7 @@ static struct language_specific language
|
||||
cplus_value_of_variable}
|
||||
,
|
||||
/* Java */
|
||||
|
|
@ -511,20 +220,11 @@ Index: gdb-6.6/gdb/varobj.c
|
|||
java_number_of_children,
|
||||
java_name_of_variable,
|
||||
java_name_of_child,
|
||||
@@ -519,7 +515,7 @@ varobj_create (char *objname,
|
||||
|
||||
/* Set language info */
|
||||
lang = variable_language (var);
|
||||
- var->root->lang = languages[lang];
|
||||
+ var->root->lang = &languages[lang];
|
||||
|
||||
/* Set ourselves as our root */
|
||||
var->root->rootvar = var;
|
||||
Index: gdb-6.6/gdb/doublest.c
|
||||
Index: gdb-6.7/gdb/doublest.c
|
||||
===================================================================
|
||||
--- gdb-6.6.orig/gdb/doublest.c
|
||||
+++ gdb-6.6/gdb/doublest.c
|
||||
@@ -94,15 +94,10 @@ get_field (const bfd_byte *data, enum fl
|
||||
--- gdb-6.7.orig/gdb/doublest.c 2007-08-23 20:08:28.000000000 +0200
|
||||
+++ gdb-6.7/gdb/doublest.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -92,15 +92,10 @@ get_field (const bfd_byte *data, enum fl
|
||||
{
|
||||
result |= (unsigned long)*(data + cur_byte) << cur_bitshift;
|
||||
cur_bitshift += FLOATFORMAT_CHAR_BIT;
|
||||
|
|
@ -544,10 +244,11 @@ Index: gdb-6.6/gdb/doublest.c
|
|||
}
|
||||
if (len < sizeof(result) * FLOATFORMAT_CHAR_BIT)
|
||||
/* Mask out bits which are not part of the field */
|
||||
diff -u -rup gdb-6.6-orig/gdb/cli/cli-cmds.c gdb-6.6/gdb/cli/cli-cmds.c
|
||||
--- gdb-6.6-orig/gdb/cli/cli-cmds.c 2007-04-08 20:49:09.000000000 +0200
|
||||
+++ gdb-6.6/gdb/cli/cli-cmds.c 2007-04-08 20:54:49.000000000 +0200
|
||||
@@ -323,7 +323,8 @@ pwd_command (char *args, int from_tty)
|
||||
Index: gdb-6.7/gdb/cli/cli-cmds.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/cli/cli-cmds.c 2007-08-23 20:08:47.000000000 +0200
|
||||
+++ gdb-6.7/gdb/cli/cli-cmds.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -320,7 +320,8 @@ pwd_command (char *args, int from_tty)
|
||||
{
|
||||
if (args)
|
||||
error (_("The \"pwd\" command does not take an argument: %s"), args);
|
||||
|
|
@ -557,10 +258,11 @@ diff -u -rup gdb-6.6-orig/gdb/cli/cli-cmds.c gdb-6.6/gdb/cli/cli-cmds.c
|
|||
|
||||
if (strcmp (gdb_dirbuf, current_directory) != 0)
|
||||
printf_unfiltered (_("Working directory %s\n (canonically %s).\n"),
|
||||
diff -u -rup gdb-6.6-orig/gdb/inflow.c gdb-6.6/gdb/inflow.c
|
||||
--- gdb-6.6-orig/gdb/inflow.c 2006-02-10 23:01:43.000000000 +0100
|
||||
+++ gdb-6.6/gdb/inflow.c 2007-04-08 20:56:48.000000000 +0200
|
||||
@@ -549,17 +549,20 @@ new_tty (void)
|
||||
Index: gdb-6.7/gdb/inflow.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/inflow.c 2007-08-23 20:08:35.000000000 +0200
|
||||
+++ gdb-6.7/gdb/inflow.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -547,17 +547,20 @@ new_tty (void)
|
||||
if (tty != 0)
|
||||
{
|
||||
close (0);
|
||||
|
|
@ -584,12 +286,13 @@ diff -u -rup gdb-6.6-orig/gdb/inflow.c gdb-6.6/gdb/inflow.c
|
|||
}
|
||||
if (tty > 2)
|
||||
close (tty);
|
||||
diff -u -rup gdb-6.6-orig/gdb/linux-nat.c gdb-6.6/gdb/linux-nat.c
|
||||
--- gdb-6.6-orig/gdb/linux-nat.c 2007-04-08 20:49:11.000000000 +0200
|
||||
+++ gdb-6.6/gdb/linux-nat.c 2007-04-08 20:54:08.000000000 +0200
|
||||
@@ -2972,7 +2972,8 @@ linux_nat_info_proc_cmd (char *args, int
|
||||
Index: gdb-6.7/gdb/linux-nat.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/linux-nat.c 2007-10-14 23:31:22.000000000 +0200
|
||||
+++ gdb-6.7/gdb/linux-nat.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -2895,7 +2895,8 @@ linux_nat_info_proc_cmd (char *args, int
|
||||
sprintf (fname1, "/proc/%lld/cmdline", pid);
|
||||
if ((procfile = fopen (fname1, "r")) > 0)
|
||||
if ((procfile = fopen (fname1, "r")) != NULL)
|
||||
{
|
||||
- fgets (buffer, sizeof (buffer), procfile);
|
||||
+ /* Unused result. */
|
||||
|
|
@ -597,10 +300,11 @@ diff -u -rup gdb-6.6-orig/gdb/linux-nat.c gdb-6.6/gdb/linux-nat.c
|
|||
printf_filtered ("cmdline = '%s'\n", buffer);
|
||||
fclose (procfile);
|
||||
}
|
||||
diff -u -rup gdb-6.6-orig/gdb/main.c gdb-6.6/gdb/main.c
|
||||
--- gdb-6.6-orig/gdb/main.c 2007-04-08 20:49:09.000000000 +0200
|
||||
+++ gdb-6.6/gdb/main.c 2007-04-08 20:55:30.000000000 +0200
|
||||
@@ -195,7 +195,8 @@ captured_main (void *data)
|
||||
Index: gdb-6.7/gdb/main.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/main.c 2007-08-23 20:08:36.000000000 +0200
|
||||
+++ gdb-6.7/gdb/main.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -193,7 +193,8 @@ captured_main (void *data)
|
||||
line[0] = '\0'; /* Terminate saved (now empty) cmd line */
|
||||
instream = stdin;
|
||||
|
||||
|
|
@ -610,23 +314,11 @@ diff -u -rup gdb-6.6-orig/gdb/main.c gdb-6.6/gdb/main.c
|
|||
current_directory = gdb_dirbuf;
|
||||
|
||||
gdb_stdout = stdio_fileopen (stdout);
|
||||
diff -u -rup gdb-6.6-orig/gdb/mi/mi-cmd-env.c gdb-6.6/gdb/mi/mi-cmd-env.c
|
||||
--- gdb-6.6-orig/gdb/mi/mi-cmd-env.c 2007-04-08 20:49:09.000000000 +0200
|
||||
+++ gdb-6.6/gdb/mi/mi-cmd-env.c 2007-04-08 20:55:11.000000000 +0200
|
||||
@@ -80,7 +80,8 @@ mi_cmd_env_pwd (char *command, char **ar
|
||||
|
||||
/* Otherwise the mi level is 2 or higher. */
|
||||
|
||||
- getcwd (gdb_dirbuf, sizeof (gdb_dirbuf));
|
||||
+ /* Unused result. */
|
||||
+ 1 && getcwd (gdb_dirbuf, sizeof (gdb_dirbuf));
|
||||
ui_out_field_string (uiout, "cwd", gdb_dirbuf);
|
||||
|
||||
return MI_CMD_DONE;
|
||||
diff -u -rup gdb-6.6-orig/gdb/top.c gdb-6.6/gdb/top.c
|
||||
--- gdb-6.6-orig/gdb/top.c 2007-04-08 20:49:10.000000000 +0200
|
||||
+++ gdb-6.6/gdb/top.c 2007-04-08 20:55:46.000000000 +0200
|
||||
@@ -1643,7 +1643,8 @@ gdb_init (char *argv0)
|
||||
Index: gdb-6.7/gdb/top.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/top.c 2007-10-14 23:38:27.000000000 +0200
|
||||
+++ gdb-6.7/gdb/top.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -1636,7 +1636,8 @@ gdb_init (char *argv0)
|
||||
|
||||
/* Run the init function of each source file */
|
||||
|
||||
|
|
@ -636,10 +328,11 @@ diff -u -rup gdb-6.6-orig/gdb/top.c gdb-6.6/gdb/top.c
|
|||
current_directory = gdb_dirbuf;
|
||||
|
||||
#ifdef __MSDOS__
|
||||
diff -u -rup gdb-6.6-orig/gdb/ui-file.c gdb-6.6/gdb/ui-file.c
|
||||
--- gdb-6.6-orig/gdb/ui-file.c 2005-12-17 23:34:03.000000000 +0100
|
||||
+++ gdb-6.6/gdb/ui-file.c 2007-04-08 20:56:21.000000000 +0200
|
||||
@@ -482,7 +482,8 @@ stdio_file_write (struct ui_file *file,
|
||||
Index: gdb-6.7/gdb/ui-file.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/ui-file.c 2007-08-23 20:08:46.000000000 +0200
|
||||
+++ gdb-6.7/gdb/ui-file.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -480,7 +480,8 @@ stdio_file_write (struct ui_file *file,
|
||||
if (stdio->magic != &stdio_file_magic)
|
||||
internal_error (__FILE__, __LINE__,
|
||||
_("stdio_file_write: bad magic number"));
|
||||
|
|
@ -649,10 +342,11 @@ diff -u -rup gdb-6.6-orig/gdb/ui-file.c gdb-6.6/gdb/ui-file.c
|
|||
}
|
||||
|
||||
static void
|
||||
diff -u -rup gdb-6.6-orig/gdb/utils.c gdb-6.6/gdb/utils.c
|
||||
--- gdb-6.6-orig/gdb/utils.c 2007-04-08 20:49:09.000000000 +0200
|
||||
+++ gdb-6.6/gdb/utils.c 2007-04-08 20:56:01.000000000 +0200
|
||||
@@ -718,7 +718,8 @@ internal_vproblem (struct internal_probl
|
||||
Index: gdb-6.7/gdb/utils.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/utils.c 2007-08-23 20:08:46.000000000 +0200
|
||||
+++ gdb-6.7/gdb/utils.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -716,7 +716,8 @@ internal_vproblem (struct internal_probl
|
||||
abort (); /* NOTE: GDB has only three calls to abort(). */
|
||||
default:
|
||||
dejavu = 3;
|
||||
|
|
@ -662,9 +356,11 @@ diff -u -rup gdb-6.6-orig/gdb/utils.c gdb-6.6/gdb/utils.c
|
|||
exit (1);
|
||||
}
|
||||
}
|
||||
--- ./gdb/gdbserver/gdbreplay.c 29 Mar 2007 01:06:47 -0000 1.14
|
||||
+++ ./gdb/gdbserver/gdbreplay.c 8 Aug 2007 20:32:12 -0000
|
||||
@@ -358,7 +358,12 @@ expect (FILE *fp)
|
||||
Index: gdb-6.7/gdb/gdbserver/gdbreplay.c
|
||||
===================================================================
|
||||
--- gdb-6.7.orig/gdb/gdbserver/gdbreplay.c 2007-08-23 20:08:48.000000000 +0200
|
||||
+++ gdb-6.7/gdb/gdbserver/gdbreplay.c 2007-10-14 23:42:39.000000000 +0200
|
||||
@@ -356,7 +356,12 @@ expect (FILE *fp)
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
|
@ -678,7 +374,7 @@ diff -u -rup gdb-6.6-orig/gdb/utils.c gdb-6.6/gdb/utils.c
|
|||
}
|
||||
while (fromlog == fromgdb);
|
||||
if (fromlog != EOL)
|
||||
@@ -385,7 +390,11 @@ play (FILE *fp)
|
||||
@@ -383,7 +388,11 @@ play (FILE *fp)
|
||||
while ((fromlog = logchar (fp)) != EOL)
|
||||
{
|
||||
ch = fromlog;
|
||||
|
|
|
|||
Loading…
Reference in a new issue