Automatic date update in version.in
[platform/upstream/binutils.git] / gdb / auxv.c
index ce0a71c..8710d2f 100644 (file)
@@ -23,7 +23,6 @@
 #include "command.h"
 #include "inferior.h"
 #include "valprint.h"
-#include "gdb_assert.h"
 #include "gdbcore.h"
 #include "observer.h"
 #include "filestuff.h"
@@ -287,6 +286,11 @@ int
 target_auxv_parse (struct target_ops *ops, gdb_byte **readptr,
                   gdb_byte *endptr, CORE_ADDR *typep, CORE_ADDR *valp)
 {
+  struct gdbarch *gdbarch = target_gdbarch();
+
+  if (gdbarch_auxv_parse_p (gdbarch))
+    return gdbarch_auxv_parse (gdbarch, readptr, endptr, typep, valp);
+
   return current_target.to_auxv_parse (&current_target, readptr, endptr,
                                       typep, valp);
 }