fix errors reported by SUSE's post-build linter
In StartRFUSocket() in gba/GBALink.cpp move a postincrement out of an expression to a following statement, because the evaluation order is undefined. In GetDevices() in wx/openal.cpp replace an #else with an #endif so that the function has a default return statement visible to the linter. In FilterThread::Entry() add a `return 0;` (ExitCode) statement at the end even though it is probably never reached. In the TransferToWindow() for the positive double validator widget in wx/widgets/wxmisc.cpp add a default `return true;`, for the rare case there is no double value, in which case the string representation would be displayed (since it is a subclass of wxGenericValidator(wxString&) .)
This commit is contained in:
parent
d118c457b1
commit
dd91abf72e
|
@ -1918,7 +1918,8 @@ static void StartRFUSocket(uint16_t value)
|
|||
if (!ok) {
|
||||
rfu_curclient = rfu_numclients;
|
||||
rfu_data.rfu_clientidx[(rfu_masterdata[0] - 0x61f1) >> 3] = rfu_numclients;
|
||||
rfu_clientlist[rfu_numclients] = rfu_masterdata[0] | (rfu_numclients++ << 16);
|
||||
rfu_clientlist[rfu_numclients] = rfu_masterdata[0] | (rfu_numclients << 16);
|
||||
rfu_numclients++;
|
||||
gbaid = (rfu_masterdata[0] - 0x61f1) >> 3;
|
||||
rfu_data.rfu_signal[gbaid] = 0xffffffff >> ((3 - (rfu_numclients - 1)) << 3);
|
||||
}
|
||||
|
|
|
@ -356,10 +356,10 @@ bool OpenAL::GetDevices(wxArrayString& names, wxArrayString& ids)
|
|||
devs += strlen(devs) + 1;
|
||||
}
|
||||
|
||||
#else
|
||||
#endif
|
||||
|
||||
// should work anyway, but must always use default driver
|
||||
return true;
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -1658,6 +1658,8 @@ public:
|
|||
done->Post();
|
||||
continue;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -393,6 +393,7 @@ bool wxPositiveDoubleValidator::TransferToWindow()
|
|||
str_val = wxString::Format(wxT("%.1f"), *double_val);
|
||||
return wxGenericValidator::TransferToWindow();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
bool wxPositiveDoubleValidator::TransferFromWindow()
|
||||
|
|
Loading…
Reference in New Issue