Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@zoffixznet
Created September 10, 2016 09:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zoffixznet/cf1ca3e208fbfc0b6c444f141ffa5333 to your computer and use it in GitHub Desktop.
Save zoffixznet/cf1ca3e208fbfc0b6c444f141ffa5333 to your computer and use it in GitHub Desktop.
zoffix@VirtualBox:/tmp/tmp.OpWb0SpB4S$ cat foo.c
#include<stdio.h>
#include<stdlib.h>
int main()
{
char *x = malloc(100);
free(x);
free(x);
return 0;
}
zoffix@VirtualBox:/tmp/tmp.OpWb0SpB4S$ gcc foo.c
zoffix@VirtualBox:/tmp/tmp.OpWb0SpB4S$ ./a.out > std.out 2> std.err
*** Error in `./a.out': double free or corruption (fasttop): 0x0000000001f81010 ***
Aborted
zoffix@VirtualBox:/tmp/tmp.OpWb0SpB4S$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment