comparison src/protocols/qq/utils.c @ 14054:51f71ad82141

[gaim-migrate @ 16667] Use GLIB_CHECK_VERSION to determine if g_str_has_prefix() is needed. As of glib 2.1.0 it was available. committer: Tailor Script <tailor@pidgin.im>
author Evan Schoenberg <evan.s@dreskin.net>
date Mon, 07 Aug 2006 23:10:37 +0000
parents 8294485b79db
children 44e1bf83dadf
comparison
equal deleted inserted replaced
14053:96ef9966aa24 14054:51f71ad82141
33 #include "prefs.h" 33 #include "prefs.h"
34 #include "utils.h" 34 #include "utils.h"
35 35
36 #define QQ_NAME_FORMAT "qq-%d" 36 #define QQ_NAME_FORMAT "qq-%d"
37 37
38 #ifndef g_str_has_prefix 38 #if !GLIB_CHECK_VERSION(2, 1, 0)
39 gint g_str_has_prefix(const gchar *str, const gchar *prefix) 39 gint g_str_has_prefix(const gchar *str, const gchar *prefix)
40 { 40 {
41 gint len = strlen(prefix); 41 gint len = strlen(prefix);
42 return !strncmp(str, prefix, len); 42 return !strncmp(str, prefix, len);
43 } 43 }