2008-05-18 [colin] 3.4.0cvs51
[claws.git] / src / common / plugin.c
index 8fa623f6c1665aa5d1850048d1f8eb467479f823..b1983c125dfae81c78391ce0c43dcbfbd0719240 100644 (file)
@@ -214,6 +214,7 @@ static gint plugin_load_deps(const gchar *filename, gchar **error)
                        dep_plugin = plugin_load(path, error);
                        if (dep_plugin == NULL) {
                                g_free(path);
+                               fclose(fp);
                                return -1;
                        }
                }
@@ -463,6 +464,8 @@ void plugin_load_all(const gchar *type)
        if ((pfile = prefs_read_open(rcpath)) == NULL ||
            (prefs_set_block_label(pfile, block) < 0)) {
                g_free(rcpath);
+               if (pfile)
+                       prefs_file_close(pfile);
                return;
        }
        g_free(block);