Revision: 7405
Author:   ek.kato
Date:     Tue Jan 10 22:57:31 2012
Log:      * Merge r7319, 7322, 7404 from trunk.

http://code.google.com/p/uim/source/detail?r=7405

Modified:
 /branches/1.7/uim/uim-custom.c

=======================================
--- /branches/1.7/uim/uim-custom.c      Thu Jan  6 18:09:56 2011
+++ /branches/1.7/uim/uim-custom.c      Tue Jan 10 22:57:31 2012
@@ -835,6 +835,7 @@
     value->as_key = uim_custom_key_get(custom_sym, getter_proc);
     break;
   default:
+    free(value);
     value = NULL;
   }

@@ -1210,8 +1211,10 @@
     goto error;

   custom_syms = uim_custom_collect_by_group(group);
-  if (!custom_syms)
+  if (!custom_syms) {
+    fclose(file);
     goto error;
+  }

   for (sym = custom_syms; *sym; sym++) {
     def_literal = uim_custom_definition_as_literal(*sym);

Reply via email to