]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Fix non-pointer type compilation error in aix-thread.c
authorAditya Vidyadhar Kamath <ADITYA.VIDYADHAR.KAMATH@ibm.com>
Fri, 20 May 2022 14:16:34 +0000 (07:16 -0700)
committerJoel Brobecker <brobecker@adacore.com>
Fri, 20 May 2022 14:16:34 +0000 (07:16 -0700)
In aix-thread.c we use ms->value_address () to get the symbol address.
This triggers the following compiler error...

     base operand of '->'  has non-pointer type 'bound_minimal_symbol'

... because ms is not a pointer.

This commit fixes this error by using ms.value_address () instead.

gdb/aix-thread.c

index 4e41cde66945148296c784fa296f9c605c5c0733..ecd8200b6928ba0dc68850d6ecef6705f8b92156 100644 (file)
@@ -360,7 +360,7 @@ pdc_symbol_addrs (pthdb_user_t user, pthdb_symbol_t *symbols, int count)
                gdb_printf (gdb_stdlog, " returning PDC_FAILURE\n");
              return PDC_FAILURE;
            }
-         symbols[i].addr = ms->value_address ();
+         symbols[i].addr = ms.value_address ();
        }
       if (debug_aix_thread)
        gdb_printf (gdb_stdlog, "  symbols[%d].addr = %s\n",
@@ -969,7 +969,7 @@ pd_enable (void)
   ms = lookup_minimal_symbol (stub_name, NULL, NULL);
   if (ms.minsym == NULL)
     return;
-  pd_brk_addr = ms->value_address ();
+  pd_brk_addr = ms.value_address ();
   if (!create_thread_event_breakpoint (target_gdbarch (), pd_brk_addr))
     return;