Indeed, isn’t RBP positioned higher up on the stack, while the data filled into the stack by the gets() function moves downward? In that case, how could RBP be overwritten with an unintended value?
I only tried to understand where is rbp positioned in stack and how does this gets funcion affect it…
New contributor
N. M. is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
1