[Telepathy-commits] [telepathy-haze/master] Coding style: (s != NULL && *s != '\0') is preferred to (s && *s)
Will Thompson
will.thompson at collabora.co.uk
Mon Aug 18 04:07:01 PDT 2008
---
src/connection-manager.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/connection-manager.c b/src/connection-manager.c
index 6d3ae54..b886f49 100644
--- a/src/connection-manager.c
+++ b/src/connection-manager.c
@@ -215,7 +215,7 @@ _translate_protocol_option (PurpleAccountOption *option,
else
def = purple_account_option_get_default_string (option);
- if (def && *def)
+ if (def != NULL && *def != '\0')
{
paramspec->def = def;
paramspec->flags |= TP_CONN_MGR_PARAM_FLAG_HAS_DEFAULT;
@@ -245,7 +245,7 @@ _translate_protocol_option (PurpleAccountOption *option,
paramspec->filter_data = valid_strings;
def = purple_account_option_get_default_list_value (option);
- if (def && *def)
+ if (def != NULL && *def != '\0')
{
paramspec->def = def;
paramspec->flags |= TP_CONN_MGR_PARAM_FLAG_HAS_DEFAULT;
--
1.5.6.3
More information about the Telepathy-commits
mailing list