mirror of
https://github.com/epasveer/seer.git
synced 2026-08-29 16:40:42 +08:00
12 lines
267 B
C
12 lines
267 B
C
#include <stdlib.h>
|
|
|
|
/** Force malloc() to be linked in our executable.
|
|
*
|
|
* GDB requires the malloc() function in order to allocate buffers for output
|
|
* commands like `echo` and `printf`.
|
|
*/
|
|
__attribute__((optimize("O0")))
|
|
void _force_malloc() {
|
|
malloc(0);
|
|
}
|