fork download
  1. #include <stdio.h>
  2. #include <stdlib.h>
  3.  
  4. void first(char **t)
  5. {
  6. *t = malloc(5*sizeof(char));
  7. }
  8.  
  9. int main(int argc, char * argv[])
  10. {
  11. char * t = NULL;
  12. printf("%p\n", t);
  13. first(&t);
  14. printf("%p\n", t);
  15. return 0;
  16. }
Compilation error #stdin compilation error #stdout 0s 2300KB
stdin
Standard input is empty
compilation info
prog.c: In function 'third':
prog.c:8:9: warning: implicit declaration of function 'strcpy' [-Wimplicit-function-declaration]
         strcpy(*msg, "third");
         ^
prog.c:8:9: warning: incompatible implicit declaration of built-in function 'strcpy'
prog.c:8:9: note: include '<string.h>' or provide a declaration of 'strcpy'
prog.c: In function 'change':
prog.c:15:9: warning: incompatible implicit declaration of built-in function 'strcpy'
         strcpy(*msg, "change");
         ^
prog.c:15:9: note: include '<string.h>' or provide a declaration of 'strcpy'
prog.c: In function 'test':
prog.c:23:9: warning: incompatible implicit declaration of built-in function 'strcpy'
         strcpy(*msg, "test");
         ^
prog.c:23:9: note: include '<string.h>' or provide a declaration of 'strcpy'
prog.c: In function 'main':
prog.c:33:9: warning: implicit declaration of function 'first' [-Wimplicit-function-declaration]
         first(&t);
         ^
/home/Szb08f/cc0dRSv2.o: In function `main':
prog.c:(.text.startup+0x1d): undefined reference to `first'
collect2: error: ld returned 1 exit status
stdout
Standard output is empty