| |
1 /* pidgin |
| |
2 * |
| |
3 * Pidgin is the legal property of its developers, whose names are too numerous |
| |
4 * to list here. Please refer to the COPYRIGHT file distributed with this |
| |
5 * source distribution. |
| |
6 * |
| |
7 * This program is free software; you can redistribute it and/or modify |
| |
8 * it under the terms of the GNU General Public License as published by |
| |
9 * the Free Software Foundation; either version 2 of the License, or |
| |
10 * (at your option) any later version. |
| |
11 * |
| |
12 * This program is distributed in the hope that it will be useful, |
| |
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| |
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| |
15 * GNU General Public License for more details. |
| |
16 * |
| |
17 * You should have received a copy of the GNU General Public License |
| |
18 * along with this program; if not, write to the Free Software |
| |
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA |
| |
20 */ |
| |
21 #ifndef _PIDGINGLIBCOMPAT_H_ |
| |
22 #define _PIDGINGLIBCOMPAT_H_ |
| |
23 |
| |
24 /* This file is internal to Pidgin. Do not use! |
| |
25 * Also, any public API should not depend on this file. |
| |
26 */ |
| |
27 |
| |
28 #if !GLIB_CHECK_VERSION(2, 28, 0) |
| |
29 |
| |
30 static inline void g_list_free_full(GList *list, GDestroyNotify free_func) |
| |
31 { |
| |
32 GList *it; |
| |
33 it = g_list_first(list); |
| |
34 while (it) |
| |
35 { |
| |
36 free_func(it->data); |
| |
37 it = g_list_next(it); |
| |
38 } |
| |
39 g_list_free(list); |
| |
40 } |
| |
41 |
| |
42 #endif /* 2.28.0 */ |
| |
43 |
| |
44 #endif /* _PIDGINGLIBCOMPAT_H_ */ |