malloc.c:3074 error?

后端 未结 1 960
没有蜡笔的小新
没有蜡笔的小新 2021-01-29 10:36

When I write a C program, I encountered a problem that is as follows:

malloc.c:3074: sYSMALLOc: Assertion (old_top == (((mbinptr) (((char *) &((av

相关标签:
1条回答
  • 2021-01-29 10:57

    It seems like the administration kept for memory allocation has been corrupted. My guess would be that you have something like a buffer overflow somewhere before this error occurs.

    As the error is a result of an earlier problem (assuming I'm right), this can be a somewhat difficult problem to fix. Perhaps a tool like valgrind can help you to detect incorrect writes to memory. If you have a small program that demonstrates the problem, I would suggest adding that code to your question.

    0 讨论(0)
提交回复
热议问题