Use gdbarch for probe::get_argument_count

The probe function get_argument_count does not need a frame, only
the current gdbarch.  Switch the code to pass gdbarch instead.
No functional changes.

gdb/ChangeLog:

	* break-catch-throw.c (fetch_probe_arguments): Use gdbarch.
	* dtrace-probe.c (dtrace_probe::get_argument_count): Likewise.
	* probe.c (probe_safe_evaluate_at_pc) (compute_probe_arg)
	(compile_probe_arg): Likewise.
	* probe.h (get_argument_count): Likewise.
	* solib-svr4.c (solib_event_probe_action): Likewise.
	* stap-probe.c (stap_probe::get_argument_count): Likewise.
This commit is contained in:
Alan Hayward 2019-08-21 15:24:02 +01:00
parent e661ef01e5
commit fe01123efb
7 changed files with 20 additions and 13 deletions

View file

@ -115,7 +115,7 @@ fetch_probe_arguments (struct value **arg0, struct value **arg1)
&& pc_probe.prob->get_name () != "rethrow"))
error (_("not stopped at a C++ exception catchpoint"));
n_args = pc_probe.prob->get_argument_count (frame);
n_args = pc_probe.prob->get_argument_count (get_frame_arch (frame));
if (n_args < 2)
error (_("C++ exception catchpoint has too few arguments"));