This is the mail archive of the gdb-patches@sources.redhat.com 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]

Re: [RFA] Assuming malloc exists in callfwmall.exp


Fernando,

chastain> How do you know whether calling an inferior function uses malloc or not?

fernando> If it does not call a string it does not.

This is a very literal question.

OK, so you know that when gdb calls an inferior function with no string
arguments (or arrays, or big structures, whatever), and the target
program does not itself call malloc(), that the call works properly.

*How* do you know?

I know because I ran callfwmall.exp, callfwmall.exp tested this behavior,
and told me that it PASSed.

I also know because I read the source code in gdb/valops.c, which is a
different avenue of knowledge.

Michael


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