Skip to content

Instantly share code, notes, and snippets.

@joequery
Created October 1, 2012 18:49
Show Gist options
  • Select an option

  • Save joequery/3813678 to your computer and use it in GitHub Desktop.

Select an option

Save joequery/3813678 to your computer and use it in GitHub Desktop.
C errors
(Precise)~/lab/c$ gcc -std=c99 -Wall ex2.c -o ex2.o
ex2.c: In function ‘splitString’:
ex2.c:4:5: warning: implicit declaration of function ‘strlen’ [-Wimplicit-function-declaration]
ex2.c:4:15: warning: incompatible implicit declaration of built-in function ‘strlen’ [enabled by default]
ex2.c:10:9: warning: implicit declaration of function ‘isdigit’ [-Wimplicit-function-declaration]
ex2.c:25:5: warning: implicit declaration of function ‘sprintf’ [-Wimplicit-function-declaration]
ex2.c:25:5: warning: incompatible implicit declaration of built-in function ‘sprintf’ [enabled by default]
ex2.c:25:5: warning: format ‘%s’ expects argument of type ‘char *’, but argument 4 has type ‘char (*)[40]’ [-Wformat]
ex2.c:26:5: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration]
ex2.c:26:5: warning: incompatible implicit declaration of built-in function ‘printf’ [enabled by default]
ex2.c:23:11: warning: unused variable ‘rem’ [-Wunused-variable]
ex2.c: In function ‘main’:
ex2.c:36:5: warning: incompatible implicit declaration of built-in function ‘printf’ [enabled by default]
ex2.c: In function ‘splitString’:
ex2.c:25:12: warning: ‘resultStr’ is used uninitialized in this function [-Wuninitialized]
(Precise)~/lab/c$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment