You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The better diagnostics in GCC 12 prints some new warnings when compiling macro.c, see bellow.
cc -Wall -O3 -DDEFAULT_INCLUDE_PATH='"/usr/local/include/avr"' -DVERSION='"1.4.2"' -c -o macro.o macro.c
macro.c: In function ‘read_macro’:
macro.c:196:36: warning: the comparison will always evaluate as ‘true’ for the address of ‘buff’ will never be NULL [-Waddress]
196 | } else if (pi->fi->buff && pi->list_file && pi->list_on) {
| ^~
In file included from macro.c:35:
avra.h:194:14: note: ‘buff’ declared here
194 | char buff[LINEBUFFER_LENGTH];
| ^~~~
Because pi->fi->buff is always non-NULL, the question is whether it should check for pi->fi->buff[i] instead ...
The better diagnostics in GCC 12 prints some new warnings when compiling
macro.c
, see bellow.Because
pi->fi->buff
is always non-NULL, the question is whether it should check forpi->fi->buff[i]
instead ...this is a case of wrong use of
strncat()
, please read for example https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83404#c1. Same applies to the nextstrncat()
call.The text was updated successfully, but these errors were encountered: