Bug #15494
Updated by Toomas Soome 6 months ago
Build errors with gcc 12:
<pre>
../common/Sun_fcSendSRL.cc: In function 'HBA_STATUS Sun_fcSendSRL(HBA_HANDLE, HBA_WWN, HBA_WWN, HBA_UINT32, void*, HBA_UINT32*)':
../common/Sun_fcSendSRL.cc:57:25: error: the address of 'HBA_wwn::wwn' will never be NULL [-Werror=address]
57 | if (wwn.wwn == NULL) {
| ^
In file included from ../common/Exceptions.h:31,
from ../common/Sun_fcSendSRL.cc:29:
/code/illumos-gate/proto/root_i386/usr/include/hbaapi.h:264:15: note: 'HBA_wwn::wwn' declared here
264 | HBA_UINT8 wwn[8];
| ^~~
cc1plus: all warnings being treated as errors
../common/Sun_fcSendRPS.cc: In function 'HBA_STATUS Sun_fcSendRPS(HBA_HANDLE, HBA_WWN, HBA_WWN, HBA_UINT32, HBA_WWN, HBA_UINT32, void*, HBA_UINT32*)':
../common/Sun_fcSendRPS.cc:62:31: error: the address of 'HBA_wwn::wwn' will never be NULL [-Werror=address]
62 | if (agent_wwn.wwn == NULL) {
| ^
In file included from ../common/Exceptions.h:31,
from ../common/Sun_fcSendRPS.cc:29:
/code/illumos-gate/proto/root_i386/usr/include/hbaapi.h:264:15: note: 'HBA_wwn::wwn' declared here
264 | HBA_UINT8 wwn[8];
| ^~~
../common/Sun_fcSendRPS.cc:67:32: error: the address of 'HBA_wwn::wwn' will never be NULL [-Werror=address]
67 | if (object_wwn.wwn == NULL) {
| ^
/code/illumos-gate/proto/root_i386/usr/include/hbaapi.h:264:15: note: 'HBA_wwn::wwn' declared here
264 | HBA_UINT8 wwn[8];
| ^~~
cc1plus: all warnings being treated as errors
../common/Sun_fcSendRPL.cc: In function 'HBA_STATUS Sun_fcSendRPL(HBA_HANDLE, HBA_WWN, HBA_WWN, HBA_UINT32, HBA_UINT32, void*, HBA_UINT32*)':
../common/Sun_fcSendRPL.cc:59:31: error: the address of 'HBA_wwn::wwn' will never be NULL [-Werror=address]
59 | if (agent_wwn.wwn == NULL) {
| ^
In file included from ../common/Exceptions.h:31,
from ../common/Sun_fcSendRPL.cc:29:
/code/illumos-gate/proto/root_i386/usr/include/hbaapi.h:264:15: note: 'HBA_wwn::wwn' declared here
264 | HBA_UINT8 wwn[8];
| ^~~
cc1plus: all warnings being treated as errors
../common/Sun_fcSendLIRR.cc: In function 'HBA_STATUS Sun_fcSendLIRR(HBA_HANDLE, HBA_WWN, HBA_WWN, HBA_UINT8, HBA_UINT8, void*, HBA_UINT32*)':
../common/Sun_fcSendLIRR.cc:58:29: error: the address of 'HBA_wwn::wwn' will never be NULL [-Werror=address]
58 | if (destWWN.wwn == NULL) {
| ^
In file included from ../common/Exceptions.h:31,
from ../common/Sun_fcSendLIRR.cc:29:
/code/illumos-gate/proto/root_i386/usr/include/hbaapi.h:264:15: note: 'HBA_wwn::wwn' declared here
264 | HBA_UINT8 wwn[8];
| ^~~
cc1plus: all warnings being treated as errors
</pre>
Testing done: build. Unfortunately, I do not have hw to test FC storage.