static void
info_sharedlibrary_command PARAMS ((char *, int));
-static int
-symbol_add_stub PARAMS ((char *));
+static int symbol_add_stub PARAMS ((PTR));
static struct so_list *
find_solib PARAMS ((struct so_list *));
static CORE_ADDR
locate_base PARAMS ((void));
-static int
-solib_map_sections PARAMS ((char *));
+static int solib_map_sections PARAMS ((PTR));
#ifdef SVR4_SHARED_LIBS
#endif
+void _initialize_solib PARAMS ((void));
+
/* If non-zero, this is a prefix that will be added to the front of the name
shared libraries with an absolute filename for loading. */
static char *solib_absolute_prefix = NULL;
static int
solib_map_sections (arg)
- char *arg;
+ PTR arg;
{
struct so_list *so = (struct so_list *) arg; /* catch_errors bogon */
char *filename;
}
init_minimal_symbol_collection ();
- make_cleanup (discard_minimal_symbols, 0);
+ make_cleanup ((make_cleanup_func) discard_minimal_symbols, 0);
while (rtc_symp)
{
if (fd == -1
|| (exec_bfd != NULL
- && fdmatch (fileno ((GDB_FILE *)(exec_bfd -> iostream)), fd)))
+ && fdmatch (fileno ((FILE *)(exec_bfd -> iostream)), fd)))
{
return (0);
}
if (! solib_cleanup_queued)
{
- make_run_cleanup (do_clear_solib);
+ make_run_cleanup (do_clear_solib, NULL);
solib_cleanup_queued = 1;
}
strncpy (new -> so_name, buffer, MAX_PATH_SIZE - 1);
new -> so_name[MAX_PATH_SIZE - 1] = '\0';
free (buffer);
- catch_errors (solib_map_sections, (char *) new,
+ catch_errors (solib_map_sections, new,
"Error while mapping shared library sections:\n",
RETURN_MASK_ALL);
}
static int
symbol_add_stub (arg)
- char *arg;
+ PTR arg;
{
register struct so_list *so = (struct so_list *) arg; /* catch_errs bogon */
CORE_ADDR text_addr = 0;
so -> objfile =
symbol_file_add (so -> so_name, so -> from_tty,
text_addr,
- 0, 0, 0);
+ 0, 0, 0, 0, 1);
return (1);
}
here, otherwise we dereference a potential dangling pointer
for each call to target_read/write_memory within this routine. */
update_coreops = core_ops.to_sections == target->to_sections;
-
+
/* Reallocate the target's section table including the new size. */
if (target -> to_sections)
{
}
}
else if (catch_errors
- (symbol_add_stub, (char *) so,
+ (symbol_add_stub, so,
"Error while reading shared library symbols:\n",
RETURN_MASK_ALL))
{
struct so_list *next;
char *bfd_filename;
+ disable_breakpoints_in_shlibs (1);
+
while (so_list_head)
{
if (so_list_head -> sections)
else
/* This happens for the executable on SVR4. */
bfd_filename = NULL;
-
+
next = so_list_head -> next;
if (bfd_filename)
free ((PTR)bfd_filename);