This is the mail archive of the gdb@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]
Other format: [Raw text]

finish for nested function calls


Hi,
 What is the expected behavior of finish when it is called from multiple
nested funtions?
e.g:
f1() calls f2():
f1()
{
  f2()
}

i do this in gdb:
b f1
finish
end
b f2
finish
end

finish takes effect only for f2() (the innermost function)
So, I get return value from f2() and gdb stops after it returns from f2().
I don't get the return value for f1().
Is that the expected beahvior?

Thanks
Smita




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