diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-25 01:32:57 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2000-01-25 01:32:57 +0000 |
commit | 8a85dc4e6fdf7b2ed7c6cd4124c74094397d931d (patch) | |
tree | 1ac628bcbc8b66287e97134e5aee9bcb91bf0940 /win32/perllib.c | |
parent | 228a48a57c3bb7d44e123c9219501dcb136fe191 (diff) | |
download | perl-8a85dc4e6fdf7b2ed7c6cd4124c74094397d931d.tar.gz |
windows build fixups from uniform DLL name change to perl56.dll
p4raw-id: //depot/perl@4884
Diffstat (limited to 'win32/perllib.c')
-rw-r--r-- | win32/perllib.c | 110 |
1 files changed, 36 insertions, 74 deletions
diff --git a/win32/perllib.c b/win32/perllib.c index 9ccf5a0043..84a2a6dc4b 100644 --- a/win32/perllib.c +++ b/win32/perllib.c @@ -87,8 +87,6 @@ perl_get_host_info(struct IPerlMemInfo* perlMemInfo, } } -#ifdef PERL_OBJECT - EXTERN_C PerlInterpreter* perl_alloc_override(struct IPerlMem** ppMem, struct IPerlMem** ppMemShared, struct IPerlMem** ppMemParse, struct IPerlEnv** ppEnv, @@ -97,33 +95,26 @@ perl_alloc_override(struct IPerlMem** ppMem, struct IPerlMem** ppMemShared, struct IPerlProc** ppProc) { PerlInterpreter *my_perl = NULL; - try - { - CPerlHost* pHost = new CPerlHost(ppMem, ppMemShared, ppMemParse, ppEnv, - ppStdIO, ppLIO, ppDir, ppSock, ppProc); - - if (pHost) { - my_perl = perl_alloc_using(pHost->m_pHostperlMem, - pHost->m_pHostperlMemShared, - pHost->m_pHostperlMemParse, - pHost->m_pHostperlEnv, - pHost->m_pHostperlStdIO, - pHost->m_pHostperlLIO, - pHost->m_pHostperlDir, - pHost->m_pHostperlSock, - pHost->m_pHostperlProc); - if (my_perl) { - CPerlObj* pPerl = (CPerlObj*)my_perl; - w32_internal_host = pHost; - } + CPerlHost* pHost = new CPerlHost(ppMem, ppMemShared, ppMemParse, ppEnv, + ppStdIO, ppLIO, ppDir, ppSock, ppProc); + + if (pHost) { + my_perl = perl_alloc_using(pHost->m_pHostperlMem, + pHost->m_pHostperlMemShared, + pHost->m_pHostperlMemParse, + pHost->m_pHostperlEnv, + pHost->m_pHostperlStdIO, + pHost->m_pHostperlLIO, + pHost->m_pHostperlDir, + pHost->m_pHostperlSock, + pHost->m_pHostperlProc); + if (my_perl) { +#ifdef PERL_OBJECT + CPerlObj* pPerl = (CPerlObj*)my_perl; +#endif + w32_internal_host = pHost; } } - catch(...) - { - win32_fprintf(stderr, "%s\n", "Error: Unable to allocate memory"); - my_perl = NULL; - } - return my_perl; } @@ -131,34 +122,29 @@ EXTERN_C PerlInterpreter* perl_alloc(void) { PerlInterpreter* my_perl = NULL; - try - { - CPerlHost* pHost = new CPerlHost(); - if (pHost) { - my_perl = perl_alloc_using(pHost->m_pHostperlMem, - pHost->m_pHostperlMemShared, - pHost->m_pHostperlMemParse, - pHost->m_pHostperlEnv, - pHost->m_pHostperlStdIO, - pHost->m_pHostperlLIO, - pHost->m_pHostperlDir, - pHost->m_pHostperlSock, - pHost->m_pHostperlProc); - if (my_perl) { - CPerlObj* pPerl = (CPerlObj*)my_perl; - w32_internal_host = pHost; - } + CPerlHost* pHost = new CPerlHost(); + if (pHost) { + my_perl = perl_alloc_using(pHost->m_pHostperlMem, + pHost->m_pHostperlMemShared, + pHost->m_pHostperlMemParse, + pHost->m_pHostperlEnv, + pHost->m_pHostperlStdIO, + pHost->m_pHostperlLIO, + pHost->m_pHostperlDir, + pHost->m_pHostperlSock, + pHost->m_pHostperlProc); + if (my_perl) { +#ifdef PERL_OBJECT + CPerlObj* pPerl = (CPerlObj*)my_perl; +#endif + w32_internal_host = pHost; } } - catch(...) - { - win32_fprintf(stderr, "%s\n", "Error: Unable to allocate memory"); - my_perl = NULL; - } - return my_perl; } +#ifdef PERL_OBJECT + EXTERN_C void perl_construct(PerlInterpreter* my_perl) { @@ -263,30 +249,6 @@ perl_parse(PerlInterpreter* my_perl, void (*xsinit)(CPerlObj*), int argc, char** #undef PL_perl_destruct_level #define PL_perl_destruct_level int dummy -#else /* !PERL_OBJECT */ - -EXTERN_C PerlInterpreter* -perl_alloc(void) -{ - PerlInterpreter *my_perl = NULL; - CPerlHost* pHost = new CPerlHost(); - if (pHost) { - my_perl = perl_alloc_using(pHost->m_pHostperlMem, - pHost->m_pHostperlMemShared, - pHost->m_pHostperlMemParse, - pHost->m_pHostperlEnv, - pHost->m_pHostperlStdIO, - pHost->m_pHostperlLIO, - pHost->m_pHostperlDir, - pHost->m_pHostperlSock, - pHost->m_pHostperlProc); - if (my_perl) { - w32_internal_host = pHost; - } - } - return my_perl; -} - #endif /* PERL_OBJECT */ #endif /* PERL_IMPLICIT_SYS */ |