comparison plugins/perl/perl-common.c @ 8593:ba075b939aa6

[gaim-migrate @ 9344] I'm not expecting any miracles, but this just *might* fix some crashes in the perl plugin... If anybody wants to take over the perl plugin, contact me. committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Tue, 06 Apr 2004 02:52:58 +0000
parents 414c701ef1ff
children 92cbf9713795
comparison
equal deleted inserted replaced
8592:1dde34c45c5b 8593:ba075b939aa6
52 SV * 52 SV *
53 gaim_perl_bless_object(void *object, const char *stash_name) 53 gaim_perl_bless_object(void *object, const char *stash_name)
54 { 54 {
55 HV *stash; 55 HV *stash;
56 HV *hv; 56 HV *hv;
57
58 if (object == NULL)
59 return NULL;
57 60
58 if (object_stashes == NULL) 61 if (object_stashes == NULL)
59 { 62 {
60 object_stashes = g_hash_table_new(g_direct_hash, g_direct_equal); 63 object_stashes = g_hash_table_new(g_direct_hash, g_direct_equal);
61 } 64 }
91 gaim_perl_ref_object(SV *o) 94 gaim_perl_ref_object(SV *o)
92 { 95 {
93 SV **sv; 96 SV **sv;
94 HV *hv; 97 HV *hv;
95 void *p; 98 void *p;
99
100 if (o == NULL)
101 return NULL;
96 102
97 hv = hvref(o); 103 hv = hvref(o);
98 104
99 if (hv == NULL) 105 if (hv == NULL)
100 return NULL; 106 return NULL;