This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] Implement show | set can-call-inferior-functions [on|off]
> From: Philippe Waroquiers <philippe.waroquiers@skynet.be>
> Cc: gdb-patches@sourceware.org
> Date: Wed, 24 Apr 2019 23:25:27 +0200
>
> Generally, returning 0 (or whatever value) can then later on
> cause problems in a script.
> For example, evaluating some function calls sometimes imply to first
> call malloc in the inferior. When can-call-inferior-functions is off,
> returning 0 (or whatever) from malloc will then cause further problems
> (such as a SEGV).
Then perhaps a built-in variable to test whether inferior calls are
allowed would be of help? Then script writers could look at that
variable and avoid calling inferior functions if they want the script
to continue running regardless, perhaps with reduced functionality.
WDYT?