From c6cf8e992dd094cca734892055bf3c24b249d4d8 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Wed, 4 Dec 2013 14:35:16 +0100 Subject: TagId3: gcc_unlikely instead of G_UNLIKELY --- src/tag/TagId3.cxx | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/tag') diff --git a/src/tag/TagId3.cxx b/src/tag/TagId3.cxx index 6e1f341a2..e04238d73 100644 --- a/src/tag/TagId3.cxx +++ b/src/tag/TagId3.cxx @@ -96,9 +96,8 @@ import_id3_string(bool is_id3v1, const id3_ucs4_t *ucs4) if (is_id3v1 && (encoding = config_get_string(CONF_ID3V1_ENCODING, nullptr)) != nullptr) { isostr = id3_ucs4_latin1duplicate(ucs4); - if (G_UNLIKELY(!isostr)) { + if (gcc_unlikely(isostr == nullptr)) return nullptr; - } utf8 = (id3_utf8_t *) g_convert_with_fallback((const char*)isostr, -1, @@ -115,9 +114,8 @@ import_id3_string(bool is_id3v1, const id3_ucs4_t *ucs4) g_free(isostr); } else { utf8 = id3_ucs4_utf8duplicate(ucs4); - if (G_UNLIKELY(!utf8)) { + if (gcc_unlikely(utf8 == nullptr)) return nullptr; - } } utf8_stripped = (id3_utf8_t *)g_strdup(g_strstrip((gchar *)utf8)); -- cgit v1.2.3