What does “double free” mean?

前端 未结 4 2076
傲寒
傲寒 2020-12-09 02:21

As the title suggests I am new to C and have a mid-term coming up shortly. I am revising from past papers currently and a recurring theme is double free problem. I understan

4条回答
  •  生来不讨喜
    2020-12-09 03:10

    Because free() will consolidate adjacent regions by managing the information stored in the tags before each region. It is something like managing the double linked list. So it would be dangerous if the buffer where ptr is pointing has been overwritten by an attack string, in which fake tags can be injected.

提交回复
热议问题