Skip to content

Instantly share code, notes, and snippets.

@justinko
Created November 12, 2011 06:58
Show Gist options
  • Save justinko/1360166 to your computer and use it in GitHub Desktop.
Save justinko/1360166 to your computer and use it in GitHub Desktop.
➜ Downloads gcc -pthread threading1.c
threading1.c:14: error: conflicting types for ‘wait’
/usr/include/sys/wait.h:255: error: previous declaration of ‘wait’ was here
threading1.c: In function ‘threadFunction’:
threading1.c:91: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:91: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:98: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:98: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c: At top level:
threading1.c:107: error: conflicting types for ‘wait’
/usr/include/sys/wait.h:255: error: previous declaration of ‘wait’ was here
threading1.c: In function ‘wait’:
threading1.c:111: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:111: warning: format ‘%i’ expects type ‘int’, but argument 3 has type ‘clock_t’
threading1.c:111: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:111: warning: format ‘%i’ expects type ‘int’, but argument 3 has type ‘clock_t’
threading1.c:118: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:118: warning: format ‘%i’ expects type ‘int’, but argument 3 has type ‘clock_t’
threading1.c:118: warning: format ‘%i’ expects type ‘int’, but argument 2 has type ‘pthread_t’
threading1.c:118: warning: format ‘%i’ expects type ‘int’, but argument 3 has type ‘clock_t’
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment