comparison libgaim/plugins/perl/common/BuddyList.xs @ 15142:66c857a355b4

[gaim-migrate @ 17927] Stephen Pope in #gaim found a bug in our perl stuff where we were creating some hash tables that used g_direct_hash instead of g_str_hash committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Sat, 09 Dec 2006 20:11:43 +0000
parents b1fcd2fc903a
children
comparison
equal deleted inserted replaced
15141:05c55c2b6c25 15142:66c857a355b4
308 GHashTable * t_GHash; 308 GHashTable * t_GHash;
309 I32 len; 309 I32 len;
310 char *t_key, *t_value; 310 char *t_key, *t_value;
311 CODE: 311 CODE:
312 t_HV = (HV *)SvRV(components); 312 t_HV = (HV *)SvRV(components);
313 t_GHash = g_hash_table_new(NULL, NULL); 313 t_GHash = g_hash_table_new(g_str_hash, g_str_equal);
314 314
315 for (t_HE = hv_iternext(t_HV); t_HE != NULL; t_HE = hv_iternext(t_HV) ) { 315 for (t_HE = hv_iternext(t_HV); t_HE != NULL; t_HE = hv_iternext(t_HV) ) {
316 t_key = hv_iterkey(t_HE, &len); 316 t_key = hv_iterkey(t_HE, &len);
317 t_SV = *hv_fetch(t_HV, t_key, len, 0); 317 t_SV = *hv_fetch(t_HV, t_key, len, 0);
318 t_value = SvPV(t_SV, PL_na); 318 t_value = SvPV(t_SV, PL_na);