From: Matthias Clasen Date: Wed, 16 Apr 2008 17:13:19 +0000 (+0000) Subject: Partically revert the last commit after realizing that X-Git-Url: http://git.openbox.org/?a=commitdiff_plain;h=07ad3555eda826224afbb306b136aa1c281ad0f5;p=dana%2Fcg-glib.git Partically revert the last commit after realizing that 2008-04-16 Matthias Clasen Partically revert the last commit after realizing that xdg_mime_media_type_equal doesn't have to init at all. * xdgmime/xdgmime.h: * xdgmime/xdgmime.c: Get rid of _xdg_mime_media_type_equal * xdgmime/xdgmimecache.c: Use xdg_mime_media_type_equal svn path=/trunk/; revision=6857 --- diff --git a/gio/ChangeLog b/gio/ChangeLog index 6833086e..b87b42c1 100644 --- a/gio/ChangeLog +++ b/gio/ChangeLog @@ -1,3 +1,13 @@ +2008-04-16 Matthias Clasen + + Partically revert the last commit after realizing that + xdg_mime_media_type_equal doesn't have to init at all. + + * xdgmime/xdgmime.h: + * xdgmime/xdgmime.c: Get rid of _xdg_mime_media_type_equal + + * xdgmime/xdgmimecache.c: Use xdg_mime_media_type_equal + 2008-04-16 Matthias Clasen Avoid possible memory corruption in xdgmime, fd.o bug 12512, diff --git a/gio/xdgmime/xdgmime.c b/gio/xdgmime/xdgmime.c index 53e11945..4552fd73 100644 --- a/gio/xdgmime/xdgmime.c +++ b/gio/xdgmime/xdgmime.c @@ -684,8 +684,8 @@ xdg_mime_mime_type_equal (const char *mime_a, } int -_xdg_mime_media_type_equal (const char *mime_a, - const char *mime_b) +xdg_mime_media_type_equal (const char *mime_a, + const char *mime_b) { char *sep; @@ -697,15 +697,6 @@ _xdg_mime_media_type_equal (const char *mime_a, return 0; } -int -xdg_mime_media_type_equal (const char *mime_a, - const char *mime_b) -{ - xdg_mime_init (); - - return _xdg_mime_media_type_equal (mime_a, mime_b); -} - #if 1 static int xdg_mime_is_super_type (const char *mime) diff --git a/gio/xdgmime/xdgmime.h b/gio/xdgmime/xdgmime.h index b8fd2d50..fde7cfe1 100644 --- a/gio/xdgmime/xdgmime.h +++ b/gio/xdgmime/xdgmime.h @@ -107,8 +107,6 @@ void xdg_mime_remove_callback (int callback_id /* Private versions of functions that don't call xdg_mime_init () */ int _xdg_mime_mime_type_equal (const char *mime_a, const char *mime_b); -int _xdg_mime_media_type_equal (const char *mime_a, - const char *mime_b); int _xdg_mime_mime_type_subclass (const char *mime, const char *base); const char *_xdg_mime_unalias_mime_type (const char *mime); diff --git a/gio/xdgmime/xdgmimecache.c b/gio/xdgmime/xdgmimecache.c index 48dd578f..8e762a17 100644 --- a/gio/xdgmime/xdgmimecache.c +++ b/gio/xdgmime/xdgmimecache.c @@ -797,7 +797,7 @@ _xdg_mime_cache_mime_type_subclass (const char *mime, #if 1 /* Handle supertypes */ if (is_super_type (ubase) && - _xdg_mime_media_type_equal (umime, ubase)) + xdg_mime_media_type_equal (umime, ubase)) return 1; #endif