diff options
author | Lucas De Marchi <lucas.demarchi@profusion.mobi> | 2010-11-27 17:39:00 -0200 |
---|---|---|
committer | Denis Kenzior <denkenz@gmail.com> | 2010-11-29 12:05:29 -0600 |
commit | 521071a7853b225713606de3e0421e680f187709 (patch) | |
tree | 57927fea85638f448436ea02706b99429ff13fc5 /gatchat/test-qcdm.c | |
parent | 00cdf2b427a788492baeb0e29b9063a36ef1effe (diff) | |
download | ofono-521071a7853b225713606de3e0421e680f187709.tar.bz2 |
gatchat: explicitly compare pointers to NULL
This patch was generated by the following semantic patch
(http://coccinelle.lip6.fr/)
// <smpl>
@fix disable is_null,isnt_null1@
expression *E;
@@
- !E
+ E == NULL
// </smpl>
Diffstat (limited to 'gatchat/test-qcdm.c')
-rw-r--r-- | gatchat/test-qcdm.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gatchat/test-qcdm.c b/gatchat/test-qcdm.c index c8a31748..a15ea9ce 100644 --- a/gatchat/test-qcdm.c +++ b/gatchat/test-qcdm.c @@ -161,13 +161,13 @@ int main(int argc, char **argv) g_option_context_free(context); - if (!option_device) + if (option_device == NULL) option_device = g_strdup("/dev/ttyUSB1"); g_print("Device: %s\n", option_device); channel = g_at_tty_open(option_device, NULL); - if (!channel) { + if (channel == NULL) { g_printerr("Failed to open QCDM device\n"); return 1; } @@ -178,7 +178,7 @@ int main(int argc, char **argv) g_io_channel_unref(channel); - if (!hdlc) + if (hdlc == NULL) return 1; if (option_debug == TRUE) |