comparison finch/libgnt/gntstyle.c @ 21780:350c93aa44d3

Plug a small leak.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Wed, 05 Dec 2007 00:42:26 +0000
parents e3e64d1e4869
children e2e57d3c0578
comparison
equal deleted inserted replaced
21779:7697b246fbcc 21780:350c93aa44d3
64 { 64 {
65 #if GLIB_CHECK_VERSION(2,6,0) 65 #if GLIB_CHECK_VERSION(2,6,0)
66 int fg = 0, bg = 0; 66 int fg = 0, bg = 0;
67 gsize n; 67 gsize n;
68 char **vals; 68 char **vals;
69 int ret = 0;
69 vals = gnt_style_get_string_list(group, key, &n); 70 vals = gnt_style_get_string_list(group, key, &n);
70 if (vals && n == 2) { 71 if (vals && n == 2) {
71 fg = gnt_colors_get_color(vals[0]); 72 fg = gnt_colors_get_color(vals[0]);
72 bg = gnt_colors_get_color(vals[1]); 73 bg = gnt_colors_get_color(vals[1]);
73 return gnt_color_add_pair(fg, bg); 74 ret = gnt_color_add_pair(fg, bg);
74 } 75 }
75 return 0; 76 g_strfreev(vals);
77 return ret;
76 #else 78 #else
77 return 0; 79 return 0;
78 #endif 80 #endif
79 } 81 }
80 82