1
0
mirror of https://github.com/irssi/irssi.git synced 2024-07-21 03:14:16 -04:00

irssi_perl_interp -> my_perl and made it non-static. should help compiling

with some weird perl implementations.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1213 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Timo Sirainen 2001-02-14 22:06:47 +00:00 committed by cras
parent f4aef7c706
commit bebb9d3de8
2 changed files with 9 additions and 7 deletions

View File

@ -1,6 +1,8 @@
#ifndef __PERL_COMMON_H
#define __PERL_COMMON_H
extern PerlInterpreter *my_perl; /* must be called my_perl or some perl implementations won't work */
/* helper defines */
#define new_pv(a) \
(newSVpv((a) == NULL ? "" : (a), (a) == NULL ? 0 : strlen(a)))

View File

@ -44,7 +44,7 @@ typedef struct {
static GSList *perl_sources;
static GSList *perl_scripts;
static PerlInterpreter *irssi_perl_interp;
PerlInterpreter *my_perl;
static void perl_source_destroy(PERL_SOURCE_REC *rec)
{
@ -90,10 +90,10 @@ static void irssi_perl_start(void)
perl_signals_start();
perl_sources = NULL;
irssi_perl_interp = perl_alloc();
perl_construct(irssi_perl_interp);
my_perl = perl_alloc();
perl_construct(my_perl);
perl_parse(irssi_perl_interp, xs_init, 3, args, NULL);
perl_parse(my_perl, xs_init, 3, args, NULL);
perl_eval_pv(eval_file_code, TRUE);
perl_common_init();
@ -175,9 +175,9 @@ static void irssi_perl_stop(void)
perl_common_deinit();
/* perl interpreter */
perl_destruct(irssi_perl_interp);
perl_free(irssi_perl_interp);
irssi_perl_interp = NULL;
perl_destruct(my_perl);
perl_free(my_perl);
my_perl = NULL;
}
static void script_fix_name(char *name)