Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wd: Fix GCC 12 build issue #540

Merged
merged 1 commit into from
Jan 18, 2023
Merged

wd: Fix GCC 12 build issue #540

merged 1 commit into from
Jan 18, 2023

Commits on Dec 31, 2022

  1. wd: Fix GCC 12 build issue

    Build errors happen with GCC 12
    
    wd.c: In function 'wd_is_isolate':
    wd.c:193:21: error: the comparison will always evaluate as 'true' for the address of 'dev_root' will never be NULL [-Werror=address]
      193 |         if (!dev || !dev->dev_root)
            |                     ^
    	In file included from wd.c:21:
    	./include/wd.h:131:14: note: 'dev_root' declared here
    	  131 |         char dev_root[PATH_STR_SIZE];
    	        |              ^~~~~~~~
    		cc1: all warnings being treated as errors
    		make[1]: *** [Makefile:816: wd.lo] Error 1
    
    Fix by using strlen(dev->dev_root).
    
    Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
    Signed-off-by: Zhangfei Gao <zhangfei.gao@linaro.org>
    zhangfeigao committed Dec 31, 2022
    Configuration menu
    Copy the full SHA
    a05f14b View commit details
    Browse the repository at this point in the history