diff -pruN old/src/packages.c new/src/packages.c --- old/src/packages.c 2004-07-22 22:20:17.000000000 +0300 +++ new/src/packages.c 2021-05-16 19:12:35.881205853 +0300 @@ -743,47 +743,7 @@ get_pixbuf_from_desktop (PkgEntry *entry str = g_malloc (256); gboolean go = TRUE; - while (((str = fgets (str, 255, desktop)) != NULL) && go) - { - if (fnmatch ("Icon=*", str, 0) == 0) - { - f = &str[5]; - if (index (f, '/')) - { - if ((p = index (f, '\n'))) - *p = '\0'; - if (entry->pixbuf != NULL) - g_free (entry->pixbuf); - entry->pixbuf = gdk_pixbuf_new_from_file (f, NULL); - - if(entry->pixbuf) - { - go = FALSE; - } - } - else - { - if ((p = index (f, '\n'))) - *p = '\0'; - p = index (f, '.'); - - if(p && (strcmp (".png", p) == 0)) - *p = '\0'; - else if(p && (strcmp (".gif", p) == 0)) - *p = '\0'; - else if(p && (strcmp (".xpm", p) == 0)) - *p = '\0'; - if (entry->pixbuf != NULL) - g_free (entry->pixbuf); - - entry->pixbuf = - gtk_icon_theme_load_icon (gtk_icon_theme_get_default(), - f, 48, 0, NULL); - go = FALSE; - } - } - } - + g_free (str); fclose (desktop);