summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDenis Kenzior <denkenz@gmail.com>2013-09-03 22:58:59 -0500
committerDenis Kenzior <denkenz@gmail.com>2013-09-03 22:58:59 -0500
commitd7ba15373753c9ec42887529b929304aa223718e (patch)
treed88d48871222cdfd7d278695b4ad19d5cfff8266 /src
parent0cdf3ced1ffa07ebc34aa2b33072a169bc3b31c7 (diff)
downloadofono-d7ba15373753c9ec42887529b929304aa223718e.tar.bz2
smsutil: Make sure to return 1/0
So the value might be used directly for D-Bus property emission. Otherwise D-Bus asserts and screws itself with: ofonod[7427]: src/sms.c:handle_mwi() process 7427: arguments to dbus_message_iter_append_basic() were incorrect, assertion "*bool_p == 0 || *bool_p == 1" failed in file ../../dbus/dbus-message.c line 2549.
Diffstat (limited to 'src')
-rw-r--r--src/smsutil.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/smsutil.c b/src/smsutil.c
index 22d0ea9e..be60ee95 100644
--- a/src/smsutil.c
+++ b/src/smsutil.c
@@ -240,7 +240,7 @@ gboolean sms_mwi_dcs_decode(guint8 dcs, enum sms_mwi_type *type,
else
ch = SMS_CHARSET_7BIT;
- act = dcs & 0x8;
+ act = (dcs & 0x8) ? TRUE : FALSE;
t = (enum sms_mwi_type) (dcs & 0x3);