From: Ell Date: Sat, 4 Aug 2018 06:14:29 +0000 (-0400) Subject: babl-cache: skip fishes with nonexistent conversions, instead of bailing X-Git-Tag: archive/raspbian/1%0.1.106-3+rpi1^2~15^2~15^2~2 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=03716a3d94d78cf6f0c4545104169f71c2738a1c;p=babl.git babl-cache: skip fishes with nonexistent conversions, instead of bailing When encountering a nonexistent conversion while loading the fish cache, skip the current fish, instead of stopping processing the cache entirely. --- diff --git a/babl/babl-cache.c b/babl/babl-cache.c index 917f028..e85216e 100644 --- a/babl/babl-cache.c +++ b/babl/babl-cache.c @@ -310,13 +310,13 @@ void babl_init_db (void) token2 = strtok_r (NULL, seps2, &tokp2); } } - else if (to_format) + else if (to_format && babl) { Babl *conv = (void*)babl_db_find(babl_conversion_db(), &token[1]); if (!conv) { - free (contents); - return; + babl_free (babl); + babl = NULL; } else babl_list_insert_last (babl->fish_path.conversion_list, conv);