Troubleshooting Steps:
1) Verify that scanf is linked correctly and the assembly code matches the calling convention.
2) Ensure that you are aligning the stack properly before calling scanf.
3) Check if printf or other functions in your code are causing issues indirectly.