Fix to check if string is NULL or not
An error occured while trying to build for riscv64 using gcc-13:
> [ 105s] In file included from ../src/nspawn/test-nspawn-tables.c:4:
> [ 105s] ../src/shared/test-tables.h: In function '_test_table.constprop':
> [ 105s] ../src/shared/test-tables.h:30:42: error: '%s' directive argument is null [-Werror=format-overflow=]
> [ 105s] 30 | printf("%s: %d → %s → %d\n", name, i, val, rev);
> [ 105s] | ^~
> [ 105s] ../src/shared/test-tables.h:30:42: error: '%s' directive argument is null [-Werror=format-overflow=]
> [ 105s] cc1: some warnings being treated as errors
The "val" can be NULL but the original code does not checking it, so the
compiler is complaining about it.
To fix this issue, ternary operator for val was used:
> printf("%s: %d → %s → %d\n", name, i, val ? val : "(null)", rev);
Change-Id: I8f1b2b45d152ec362977154f62e333807392da76
Signed-off-by: SangYoun Kwak <sy.kwak@samsung.com>