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
---
unit/test-caif.c|2 +-
unit/test-mux.c |2 +-
unit/test-simutil.c |4 ++--
3 files changed, 4
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
---
examples/nettime.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/examples/nettime.c
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
---
gatchat/gatchat.c | 46 +++---
gatchat/gathdlc.c |8
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
---
gdbus/object.c | 24
gdbus/polkit.c |2 +-
gdbus/watch.c | 21 ++---
3
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
---
plugins/bluetooth.c |6 +++---
plugins/calypso.c |4 ++--
plugins/hfp.c | 20
Hi Lucas
+M13: Check for pointer being NULL
+=
+
+When checking if a pointer or a return value is NULL, explicitly
+compare to NULL rather than use the shorter check with ! operator.
+
+Example:
+1)
+array = g_try_new0(int, 20);
+if (!array) // Wrong
Hi Jeevaka,
On 11/26/2010 12:23 AM, Jeevaka Badrappan wrote:
---
src/simutil.h |2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
Patch has been applied, thanks.
Regards,
-Denis
___
ofono mailing list
ofono@ofono.org
Hi Lucas,
On 11/26/2010 06:44 PM, Lucas De Marchi wrote:
---
plugins/phonesim.c | 140
++--
1 files changed, 136 insertions(+), 4 deletions(-)
diff --git a/plugins/phonesim.c b/plugins/phonesim.c
index d2faf42..be2f931 100644
---
On Sat, Nov 27, 2010 at 1:57 PM, rajesh.naga...@elektrobit.com wrote:
+3)
+array = g_try_new0(int, 20);
+if (!array) // Correct
Shouldn't be if (array == NULL) // Correct :)?
You are right.
Thanks, fixed.
Lucas De Marchi
___
ofono mailing list
---
plugins/phonesim.c | 150 ++--
1 files changed, 146 insertions(+), 4 deletions(-)
diff --git a/plugins/phonesim.c b/plugins/phonesim.c
index d2faf42..d10eda8 100644
--- a/plugins/phonesim.c
+++ b/plugins/phonesim.c
@@ -46,6 +46,7 @@
#include
---
TODO | 11 ---
doc/features.txt |7 +++
2 files changed, 7 insertions(+), 11 deletions(-)
diff --git a/TODO b/TODO
index c484871..4443ac1 100644
--- a/TODO
+++ b/TODO
@@ -479,17 +479,6 @@ Miscellaneous
Complexity: C2
Owner: Gustavo F Padovan
---
doc/coding-style.txt | 21 +
1 files changed, 21 insertions(+), 0 deletions(-)
diff --git a/doc/coding-style.txt b/doc/coding-style.txt
index eccdacc..9dfdc09 100644
--- a/doc/coding-style.txt
+++ b/doc/coding-style.txt
@@ -209,6 +209,27 @@ However if the enum comes
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
---
gisi/client.c | 46 +++---
gisi/iter.c |2 +-
gisi/server.c |6
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
---
examples/nettime.c |2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/examples/nettime.c
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
---
gatchat/gatchat.c | 46 +++---
gatchat/gathdlc.c |8
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
---
gdbus/object.c | 24
gdbus/polkit.c |2 +-
gdbus/watch.c | 21 ++---
3
+ void (*remove)(struct ofono_ctm *tt);
+ void (*query_tty)(struct ofono_ctm *tt,
+ ofono_ctm_query_cb_t cb,
+ void *data);
+ void (*set_tty)(struct ofono_ctm *tt,
+ int enable,
I also changed this to
17 matches
Mail list logo