static void
svr4_pspace_data_cleanup (struct program_space *pspace, void *arg)
{
- struct svr4_info *info;
-
- info = program_space_data (pspace, solib_svr4_pspace_data);
- if (info == NULL)
- return;
+ struct svr4_info *info = arg;
free_probes_table (info);
free_solib_list (info);
svr4_read_so_list (CORE_ADDR lm, CORE_ADDR prev_lm,
struct so_list ***link_ptr_ptr, int ignore_first)
{
+ struct so_list *first = NULL;
CORE_ADDR next_lm;
for (; lm != 0; prev_lm = lm, lm = next_lm)
{
struct svr4_info *info = get_svr4_info ();
+ first = new;
info->main_lm_addr = new->lm_info->lm_addr;
do_cleanups (old_chain);
continue;
SO_NAME_MAX_PATH_SIZE - 1, &errcode);
if (errcode != 0)
{
- warning (_("Can't read pathname for load map: %s."),
- safe_strerror (errcode));
+ /* If this entry's l_name address matches that of the
+ inferior executable, then this is not a normal shared
+ object, but (most likely) a vDSO. In this case, silently
+ skip it; otherwise emit a warning. */
+ if (first == NULL
+ || new->lm_info->l_name != first->lm_info->l_name)
+ warning (_("Can't read pathname for load map: %s."),
+ safe_strerror (errcode));
do_cleanups (old_chain);
continue;
}
{
VEC (probe_p) *probes[NUM_PROBES];
int all_probes_found = 1;
+ int checked_can_use_probe_arguments = 0;
int i;
memset (probes, 0, sizeof (probes));
for (i = 0; i < NUM_PROBES; i++)
{
const char *name = probe_info[i].name;
+ struct probe *p;
char buf[32];
/* Fedora 17 and Red Hat Enterprise Linux 6.2-6.4
all_probes_found = 0;
break;
}
+
+ /* Ensure probe arguments can be evaluated. */
+ if (!checked_can_use_probe_arguments)
+ {
+ p = VEC_index (probe_p, probes[i], 0);
+ if (!can_evaluate_probe_arguments (p))
+ {
+ all_probes_found = 0;
+ break;
+ }
+ checked_can_use_probe_arguments = 1;
+ }
}
if (all_probes_found)