This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFC: remove pop_target


>>>>> "Pedro" == Pedro Alves <palves@redhat.com> writes:

>> PR remote/15256, PR remote/15266:
>> * bfd-target.c (target_bfd_reopen): Initialize to_magic.
>> * monitor.c (monitor_detach): Use unpush_target.
>> * remote-m32r-sdi.c (m32r_detach): Use unpush_target.
>> * remote-mips.c (mips_detach): Use unpush_target.  Don't
>> call mips_close.
>> * remote-sim.c (gdbsim_detach): Use unpush_target.
>> * target.c (pop_target): Remove.
>> (pop_all_targets_above): Don't call target_close.
>> (target_close): Assert that the target is unpushed.
>> * target.h (pop_target): Don't declare.
>> * tracepoint.c (tfile_open): Use unpush_target.

Pedro> This looks good to me.

Thanks, I'm checking it in now.

>> --- a/gdb/monitor.c
>> +++ b/gdb/monitor.c
>> @@ -877,7 +877,7 @@ monitor_close (void)
>> static void
>> monitor_detach (struct target_ops *ops, char *args, int from_tty)
>> {
>> -  pop_target ();		/* calls monitor_close to do the real work.  */
>> +  unpush_target (ops);

Pedro> Nit, but you've preserved the similar comment in the other hunks.

I've restored the comment.
I'm not reposting the patch since this is a trivial change.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]