summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWill Thompson <will.thompson@collabora.co.uk>2011-10-04 00:20:14 +0100
committerWill Thompson <will.thompson@collabora.co.uk>2011-11-03 18:32:24 +0000
commit933af070afdc7a3a1df333c318743e0ba115f3a5 (patch)
treeb32b79352b05f7525523bbcc3bd8e514d71733a9
parent2941264d571f3bd23739f7bbdbb350c53355398b (diff)
Remove redundant CHECK_STR_EMPTY macro
-rw-r--r--src/connection.c2
-rw-r--r--src/ft-channel.c2
-rw-r--r--src/jingle-session.c2
-rw-r--r--src/util.h2
-rw-r--r--src/vcard-manager.c2
5 files changed, 4 insertions, 6 deletions
diff --git a/src/connection.c b/src/connection.c
index 5f89dbb37..606e398fb 100644
--- a/src/connection.c
+++ b/src/connection.c
@@ -3812,7 +3812,7 @@ gabble_connection_send_presence (GabbleConnection *conn,
lm_message_node_add_own_nick (
wocky_stanza_get_top_node (message), conn);
- if (!CHECK_STR_EMPTY(status))
+ if (!tp_str_empty (status))
lm_message_node_add_child (
wocky_stanza_get_top_node (message), "status", status);
diff --git a/src/ft-channel.c b/src/ft-channel.c
index 70b73f7ec..cc2eb57c4 100644
--- a/src/ft-channel.c
+++ b/src/ft-channel.c
@@ -1471,7 +1471,7 @@ gabble_file_transfer_channel_offer_file (GabbleFileTransferChannel *self,
gboolean jingle_share = FALSE;
const gchar *si_resource = NULL;
const gchar *share_resource = NULL;
- g_assert (!CHECK_STR_EMPTY (self->priv->filename));
+ g_assert (!tp_str_empty (self->priv->filename));
g_assert (self->priv->size != GABBLE_UNDEFINED_FILE_SIZE);
g_return_val_if_fail (self->priv->bytestream == NULL, FALSE);
g_return_val_if_fail (self->priv->gtalk_file_collection == NULL, FALSE);
diff --git a/src/jingle-session.c b/src/jingle-session.c
index 2981e3e83..d65721cfa 100644
--- a/src/jingle-session.c
+++ b/src/jingle-session.c
@@ -2092,7 +2092,7 @@ gabble_jingle_session_terminate (GabbleJingleSession *sess,
lm_message_node_add_child (r, reason_elt, NULL);
- if (!CHECK_STR_EMPTY(text))
+ if (!tp_str_empty (text))
lm_message_node_add_child (r, "text", text);
}
diff --git a/src/util.h b/src/util.h
index 9727e60de..fc83ee3b6 100644
--- a/src/util.h
+++ b/src/util.h
@@ -35,8 +35,6 @@
#include "types.h"
-#define CHECK_STR_EMPTY(x) ((x) == NULL || (x)[0] == '\0')
-
typedef GSList * NodeIter;
#define node_iter(node) (node->children)
#define node_iter_next(i) (g_slist_next (i))
diff --git a/src/vcard-manager.c b/src/vcard-manager.c
index ba8e834f7..71c3b2b08 100644
--- a/src/vcard-manager.c
+++ b/src/vcard-manager.c
@@ -847,7 +847,7 @@ observe_vcard (GabbleConnection *conn,
{
const gchar *fn = lm_message_node_get_value (fn_node);
- if (!CHECK_STR_EMPTY(fn))
+ if (!tp_str_empty (fn))
{
field = "<FN>";
alias = g_strdup (fn);