mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-07-24 02:14:24 +00:00
Fixes constant logical operand warning on OS X build.
This was SVN commit r11190.
This commit is contained in:
@@ -451,7 +451,7 @@ JSBool JSI_IGUIObject::setProperty(JSContext* cx, JSObject* obj, jsid id, JSBool
|
||||
{
|
||||
JSBool value;
|
||||
if (JS_ValueToBoolean(cx, *vp, &value) == JS_TRUE)
|
||||
GUI<bool>::SetSetting(e, propName, value||0); // ||0 to avoid int-to-bool compiler warnings
|
||||
GUI<bool>::SetSetting(e, propName, value == JS_TRUE);
|
||||
else
|
||||
{
|
||||
JS_ReportError(cx, "Cannot convert value to bool");
|
||||
|
||||
Reference in New Issue
Block a user