You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

basic_double_free.c 230 B

3 years ago
12345678910111213
  1. #include <memory.h>
  2. #include <stdlib.h>
  3. #include <stdio.h>
  4. int main(void) {
  5. int* i_ptr = malloc(sizeof(int));
  6. if (i_ptr) {
  7. (void)printf("malloc() success...\n");
  8. // Double free
  9. free(i_ptr);
  10. free(i_ptr);
  11. }
  12. }

No Description

Contributors (1)