/in/database.c: In function 'strfind':
/in/database.c:8:18: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for(int i=0;i<strlen(lmz);i++)
^
/in/database.c: In function 'list':
/in/database.c:85:27: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (int j = 0; j < strlen(db->tables[i].name); j++) {
^
/in/database.c: In function 'delete':
/in/database.c:148:10: warning: unused variable 'temp' [-Wunused-variable]
char temp[MAX_ASSIGNMENT][MAX_NAME];
^~~~
/in/database.c:147:9: warning: unused variable 'm' [-Wunused-variable]
int m = 0;
^
/in/database.c:146:9: warning: unused variable 'j' [-Wunused-variable]
int j = 0;
^
/in/database.c:145:9: warning: unused variable 'cp' [-Wunused-variable]
int cp[100];
^~
/in/database.c:144:9: warning: unused variable 'ci' [-Wunused-variable]
int ci[100];
^~
/in/database.c: In function 'main':
/in/database.c:343:9: warning: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
gets(command);
^~~~
fgets
/in/database.c:349:36: warning: format '%s' expects argument of type 'char *', but argument 3 has type 'char (*)[15]' [-Wformat=]
sscanf(command, "LOAD %s\n", &str);
~^ ~~~~
/in/database.c: In function 'strfind':
/in/database.c:14:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
In file included from /usr/include/stdio.h:862:0,
from /in/database.c:1:
In function 'fgets',
inlined from 'load' at /in/database.c:30:12:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:260:9: warning: call to '__fgets_chk_warn' declared with attribute warning: fgets called with bigger size than length of destination buffer
return __fgets_chk_warn (__s, __bos (__s), __n, __stream);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/tmp/cco9kk7g.o: In function `main':
database.c:(.text.startup+0xce): warning: the `gets' function is dangerous and should not be used.