open
https://gitlab.synchro.net/main/sbbs/-/issues/621
New compiler warnings gcc version 11.4.0~~~Compiling scfgxfr1.cscfgxfr1.c: In function ‘xfer_opts’:scfgxfr1.c:412:88: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 412 | if((cfg.fview = (fview_t**)new_item(cfg.fview, sizeof(fview_t), i, &cfg.total_fviews)) == NULL) { | ~~~^~~~~~ | | | fview_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘fview_t **’ 166 | void** new_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~scfgxfr1.c:544:88: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 544 | if((cfg.ftest = (ftest_t**)new_item(cfg.ftest, sizeof(ftest_t), i, &cfg.total_ftests)) == NULL) { | ~~~^~~~~~ | | | ftest_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘ftest_t **’ 166 | void** new_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~scfgxfr1.c:698:92: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 698 | if((cfg.dlevent = (dlevent_t**)new_item(cfg.dlevent, sizeof(dlevent_t), i, &cfg.total_dlevents)) == NULL) { |
~~~^~~~~~~~ | | | dlevent_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘dlevent_t **’ 166 | void** new_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~scfgxfr1.c:844:88: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 844 | if((cfg.fextr = (fextr_t**)new_item(cfg.fextr, sizeof(fextr_t), i, &cfg.total_fextrs)) == NULL) { | ~~~^~~~~~ | | | fextr_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘fextr_t **’ 166 | void** new_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~scfgxfr1.c:982:88: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 982 | if((cfg.fcomp = (fcomp_t**)new_item(cfg.fcomp, sizeof(fcomp_t), i, &cfg.total_fcomps)) == NULL) { | ~~~^~~~~~ | | | fcomp_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘fcomp_t **’ 166 | void** new
_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~scfgxfr1.c:1124:86: warning: passing argument 1 of ‘new_item’ from incompatible pointer type [-Wincompatible-pointer-types] 1124 | if((cfg.prot = (prot_t**)new_item(cfg.prot, sizeof(prot_t), i, &cfg.total_prots)) == NULL) { | ~~~^~~~~ | | | prot_t **In file included from scfgxfr1.c:20:scfg.h:166:23: note: expected ‘void **’ but argument is of type ‘prot_t **’ 166 | void** new_item(void* list[], size_t size, int index, int* total); | ~~~~~~^~~~~~~~~
--- SBBSecho 3.20-Linux
* Origin: Vertrauen - [vert/cvs/bbs].synchro.net (1:103/705)