Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
任何人都可以解释有关堆栈损坏和静态损坏之间区别的见解吗?
堆栈损坏是由于程序中的操作导致的内存损坏,例如无界数组复制会导致覆盖堆栈中的元素(局部变量、返回地址等)。结果,程序崩溃或表现出未定义的行为。静态损坏(我猜你的意思是静态变量的损坏)只是当变量由于某种编程错误而出现意外值并导致瞬态错误时