We're a community of 1076K IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,075,803 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

Ubuntu 12.04 - GDB & stdcall

Is there an option that can be passed to GDB to make it happy with callee cleaning up stack.

        push    eax
        push    rbp
        push     0
        call    AddVals
        ret

AddVals enter   28, 0

    ;... Bunch of code

        leave
        ret     24

1) If I single step "si" into AddVals and right through it it works ok
2) If I single step into AddVals and then try to continue untill next frame, or step over AddVals "ni", it will usually complete program or stop at some arbitrary point.

3) If I set a breakpoint at callers return it works ok

Assembler is NASM "-felf64" and I'm not using "-g"

1
Contributor
0
Replies
1
View
ShiftLeft
Light Poster
31 posts since Jun 2012
Reputation Points: 0
Solved Threads: 0
Skill Endorsements: 0

This article has been dead for over three months: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
 
© 2013 DaniWeb® LLC
Page rendered in 0.0645 seconds using 2.69MB