1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
|
diff --git a/src/caja-python.c b/src/caja-python.c
index 60841b6..e516ff8 100644
--- a/src/caja-python.c
+++ b/src/caja-python.c
@@ -107,7 +107,7 @@ caja_python_load_file(GTypeModule *type_module,
}
main_locals = PyModule_GetDict(main_module);
- module = PyImport_ImportModuleEx((char *) filename, main_locals, main_locals, NULL);
+ module = PyImport_ImportModuleEx(filename, main_locals, main_locals, NULL);
if (!module)
{
PyErr_Print();
@@ -130,7 +130,7 @@ caja_python_load_file(GTypeModule *type_module,
gtype = caja_python_object_get_type(type_module, value);
g_array_append_val(all_types, gtype);
- all_pyfiles = g_list_append(all_pyfiles, (gchar*)filename);
+ all_pyfiles = g_list_append(all_pyfiles, g_strdup(filename));
}
}
@@ -336,7 +336,7 @@ caja_module_shutdown(void)
Py_Finalize();
g_array_free(all_types, TRUE);
- g_list_free (all_pyfiles);
+ g_list_free_full(all_pyfiles, g_free);
}
void
|