diff options
author | Gurusamy Sarathy <gsar@cpan.org> | 2001-08-31 20:58:38 +0000 |
---|---|---|
committer | Gurusamy Sarathy <gsar@cpan.org> | 2001-08-31 20:58:38 +0000 |
commit | acfe0abcedaf592fb4b9cb69ce3468308ae99d91 (patch) | |
tree | a2ca08c77d2b63d1777d0b228ff53362895c1624 /win32 | |
parent | 25f58aea15b072f74afcee1b9074d33e8e7348b5 (diff) | |
download | perl-acfe0abcedaf592fb4b9cb69ce3468308ae99d91.tar.gz |
remove deprecated PERL_OBJECT cruft, it has long since stopped
working in 5.7.x
p4raw-id: //depot/perl@11803
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Makefile | 41 | ||||
-rw-r--r-- | win32/config_h.PL | 3 | ||||
-rw-r--r-- | win32/dl_win32.xs | 22 | ||||
-rw-r--r-- | win32/makefile.mk | 38 | ||||
-rw-r--r-- | win32/perlhost.h | 52 | ||||
-rw-r--r-- | win32/perllib.c | 134 | ||||
-rw-r--r-- | win32/win32.c | 137 | ||||
-rw-r--r-- | win32/win32.h | 55 | ||||
-rw-r--r-- | win32/win32sck.c | 41 | ||||
-rw-r--r-- | win32/win32thread.c | 6 |
10 files changed, 116 insertions, 413 deletions
diff --git a/win32/Makefile b/win32/Makefile index b4d56aefe4..0287a189f1 100644 --- a/win32/Makefile +++ b/win32/Makefile @@ -79,17 +79,6 @@ USE_PERLIO = define #USE_5005THREADS = define # -# WARNING! This option is deprecated and will eventually go away (enable -# USE_MULTI instead). -# -# uncomment next line if you want to use the PERL_OBJECT build option. -# DO NOT ENABLE unless you have legacy code that relies on the C++ -# CPerlObj class that was available in 5.005. This cannot be enabled -# if you ask for USE_5005THREADS above. -# -#USE_OBJECT = define - -# # uncomment one of the following lines if you are using either # Visual C++ 2.x or Visual C++ 6.x (aka Visual Studio 98) # @@ -206,13 +195,6 @@ D_CRYPT = define CRYPT_FLAG = -DHAVE_DES_FCRYPT !ENDIF -!IF "$(USE_OBJECT)" == "define" -PERL_MALLOC = undef -USE_5005THREADS = undef -USE_MULTI = undef -USE_IMP_SYS = define -!ENDIF - !IF "$(PERL_MALLOC)" == "" PERL_MALLOC = undef !ENDIF @@ -233,10 +215,6 @@ PERL_MALLOC = undef USE_MULTI = undef !ENDIF -!IF "$(USE_OBJECT)" == "" -USE_OBJECT = undef -!ENDIF - !IF "$(USE_ITHREADS)" == "" USE_ITHREADS = undef !ENDIF @@ -253,16 +231,16 @@ USE_PERLIO = undef USE_PERLCRT = undef !ENDIF -!IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" == "defineundefundefundef" +!IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)" == "defineundefundef" USE_MULTI = define !ENDIF -!IF "$(USE_ITHREADS)$(USE_MULTI)$(USE_OBJECT)" == "defineundefundef" +!IF "$(USE_ITHREADS)$(USE_MULTI)" == "defineundef" USE_MULTI = define USE_5005THREADS = undef !ENDIF -!IF "$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" != "undefundefundef" +!IF "$(USE_MULTI)$(USE_5005THREADS)" != "undefundef" BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_CONTEXT !ENDIF @@ -274,9 +252,6 @@ BUILDOPT = $(BUILDOPT) -DPERL_IMPLICIT_SYS PROCESSOR_ARCHITECTURE = x86 !ENDIF -!IF "$(USE_OBJECT)" == "define" -ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-object -!ELSE !IF "$(USE_5005THREADS)" == "define" ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-thread !ELSE @@ -290,7 +265,6 @@ ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE) !ENDIF !ENDIF !ENDIF -!ENDIF !IF "$(USE_PERLIO)" == "define" BUILDOPT = $(BUILDOPT) -DUSE_PERLIO @@ -368,11 +342,6 @@ OPTIMIZE = -O1 -MD -DNDEBUG LINK_DBG = -release !ENDIF -!IF "$(USE_OBJECT)" == "define" -OPTIMIZE = $(OPTIMIZE) $(CXX_FLAG) -BUILDOPT = $(BUILDOPT) -DPERL_OBJECT -!ENDIF - !IF "$(USE_PERLCRT)" != "define" BUILDOPT = $(BUILDOPT) -DPERL_MSVCRT_READFIX !ENDIF @@ -535,9 +504,7 @@ EXTRACORE_SRC = $(EXTRACORE_SRC) perllib.c EXTRACORE_SRC = $(EXTRACORE_SRC) ..\malloc.c !ENDIF -!IF "$(USE_OBJECT)" != "define" EXTRACORE_SRC = $(EXTRACORE_SRC) ..\perlio.c -!ENDIF WIN32_SRC = \ .\win32.c \ @@ -839,7 +806,7 @@ $(MINIWIN32_OBJ) : $(CORE_NOCFG_H) # -DPERL_IMPLICIT_SYS needs C++ for perllib.c # This is the only file that depends on perlhost.h, vmem.h, and vdir.h -!IF "$(USE_IMP_SYS)$(USE_OBJECT)" == "defineundef" +!IF "$(USE_IMP_SYS)" == "define" perllib$(o) : perllib.c .\perlhost.h .\vdir.h .\vmem.h $(CC) -c -I. $(CFLAGS_O) $(CXX_FLAG) $(OBJOUT_FLAG)$@ perllib.c !ENDIF diff --git a/win32/config_h.PL b/win32/config_h.PL index a0ee22d305..607c4844a2 100644 --- a/win32/config_h.PL +++ b/win32/config_h.PL @@ -2,7 +2,6 @@ use Config; use File::Compare qw(compare); use File::Copy qw(copy); -my $OBJ = 1 if $Config{'ccflags'} =~ /PERL_OBJECT/i; my $name = $0; $name =~ s#^(.*)\.PL$#../$1.SH#; my %opt; @@ -73,7 +72,7 @@ chmod(0666,"../lib/CORE/config.h"); copy("$file.new","../lib/CORE/config.h") || die "Cannot copy:$!"; chmod(0444,"../lib/CORE/config.h"); -if (!$OBJ && compare("$file.new",$file)) +if (compare("$file.new",$file)) { warn "$file has changed\n"; chmod(0666,$file); diff --git a/win32/dl_win32.xs b/win32/dl_win32.xs index d959fbdae6..fb3e3321f8 100644 --- a/win32/dl_win32.xs +++ b/win32/dl_win32.xs @@ -30,16 +30,12 @@ calls. #include "perl.h" #include "win32.h" -#ifdef PERL_OBJECT -#define NO_XSLOCKS -#endif /* PERL_OBJECT */ - #include "XSUB.h" static SV *error_sv; static char * -OS_Error_String(pTHXo) +OS_Error_String(pTHX) { DWORD err = GetLastError(); STRLEN len; @@ -52,9 +48,9 @@ OS_Error_String(pTHXo) #include "dlutils.c" /* SaveError() etc */ static void -dl_private_init(pTHXo) +dl_private_init(pTHX) { - (void)dl_generic_private_init(aTHXo); + (void)dl_generic_private_init(aTHX); } /* @@ -96,7 +92,7 @@ dl_static_linked(char *filename) MODULE = DynaLoader PACKAGE = DynaLoader BOOT: - (void)dl_private_init(aTHXo); + (void)dl_private_init(aTHX); void * dl_load_file(filename,flags=0) @@ -114,8 +110,8 @@ dl_load_file(filename,flags=0) DLDEBUG(2,PerlIO_printf(Perl_debug_log," libref=%x\n", RETVAL)); ST(0) = sv_newmortal() ; if (RETVAL == NULL) - SaveError(aTHXo_ "load_file:%s", - OS_Error_String(aTHXo)) ; + SaveError(aTHX_ "load_file:%s", + OS_Error_String(aTHX)) ; else sv_setiv( ST(0), (IV)RETVAL); } @@ -131,8 +127,8 @@ dl_find_symbol(libhandle, symbolname) DLDEBUG(2,PerlIO_printf(Perl_debug_log," symbolref = %x\n", RETVAL)); ST(0) = sv_newmortal() ; if (RETVAL == NULL) - SaveError(aTHXo_ "find_symbol:%s", - OS_Error_String(aTHXo)) ; + SaveError(aTHX_ "find_symbol:%s", + OS_Error_String(aTHX)) ; else sv_setiv( ST(0), (IV)RETVAL); @@ -154,7 +150,7 @@ dl_install_xsub(perl_name, symref, filename="$Package") DLDEBUG(2,PerlIO_printf(Perl_debug_log,"dl_install_xsub(name=%s, symref=%x)\n", perl_name, symref)); ST(0) = sv_2mortal(newRV((SV*)newXS(perl_name, - (void(*)(pTHXo_ CV *))symref, + (void(*)(pTHX_ CV *))symref, filename))); diff --git a/win32/makefile.mk b/win32/makefile.mk index b15e98405c..0b4b685c6d 100644 --- a/win32/makefile.mk +++ b/win32/makefile.mk @@ -81,17 +81,6 @@ USE_PERLIO = define #USE_5005THREADS *= define # -# WARNING! This option is deprecated and will eventually go away (enable -# USE_MULTI instead). -# -# uncomment next line if you want to use the PERL_OBJECT build option. -# DO NOT ENABLE unless you have legacy code that relies on the C++ -# CPerlObj class that was available in 5.005. This cannot be enabled -# if you ask for USE_5005THREADS above. -# -#USE_OBJECT *= define - -# # uncomment exactly one of the following # # Visual C++ 2.x @@ -236,13 +225,6 @@ D_CRYPT = define CRYPT_FLAG = -DHAVE_DES_FCRYPT .ENDIF -.IF "$(USE_OBJECT)" == "define" -PERL_MALLOC != undef -USE_5005THREADS != undef -USE_MULTI != undef -USE_IMP_SYS != define -.ENDIF - PERL_MALLOC *= undef USE_5005THREADS *= undef @@ -256,22 +238,21 @@ PERL_MALLOC != undef .ENDIF USE_MULTI *= undef -USE_OBJECT *= undef USE_ITHREADS *= undef USE_IMP_SYS *= undef USE_PERLIO *= undef USE_PERLCRT *= undef -.IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" == "defineundefundefundef" +.IF "$(USE_IMP_SYS)$(USE_MULTI)$(USE_5005THREADS)" == "defineundefundef" USE_MULTI != define .ENDIF -.IF "$(USE_ITHREADS)$(USE_MULTI)$(USE_OBJECT)" == "defineundefundef" +.IF "$(USE_ITHREADS)$(USE_MULTI)" == "defineundef" USE_MULTI != define USE_5005THREADS != undef .ENDIF -.IF "$(USE_MULTI)$(USE_5005THREADS)$(USE_OBJECT)" != "undefundefundef" +.IF "$(USE_MULTI)$(USE_5005THREADS)" != "undefundef" BUILDOPT += -DPERL_IMPLICIT_CONTEXT .ENDIF @@ -283,9 +264,7 @@ BUILDOPT += -DPERL_IMPLICIT_SYS PROCESSOR_ARCHITECTURE *= x86 -.IF "$(USE_OBJECT)" == "define" -ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-object -.ELIF "$(USE_5005THREADS)" == "define" +.IF "$(USE_5005THREADS)" == "define" ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-thread .ELIF "$(USE_MULTI)" == "define" ARCHNAME = MSWin32-$(PROCESSOR_ARCHITECTURE)-multi @@ -510,11 +489,6 @@ BUILDOPT += -DPERL_MSVCRT_READFIX .ENDIF -.IF "$(USE_OBJECT)" == "define" -OPTIMIZE += $(CXX_FLAG) -BUILDOPT += -DPERL_OBJECT -.ENDIF - CFLAGS_O = $(CFLAGS) $(BUILDOPT) # used to allow local linking flags that are not propogated into Config.pm, @@ -686,9 +660,7 @@ EXTRACORE_SRC += perllib.c EXTRACORE_SRC += ..\malloc.c .ENDIF -.IF "$(USE_OBJECT)" != "define" EXTRACORE_SRC += ..\perlio.c -.ENDIF WIN32_SRC = \ .\win32.c \ @@ -963,7 +935,7 @@ $(MINIWIN32_OBJ) : $(CORE_NOCFG_H) # This is the only file that depends on perlhost.h, vmem.h, and vdir.h perllib$(o) : perllib.c .\perlhost.h .\vdir.h .\vmem.h -.IF "$(USE_IMP_SYS)$(USE_OBJECT)" == "defineundef" +.IF "$(USE_IMP_SYS)" == "define" $(CC) -c -I. $(CFLAGS_O) $(CXX_FLAG) $(OBJOUT_FLAG)$@ perllib.c .ELSE $(CC) -c -I. $(CFLAGS_O) $(OBJOUT_FLAG)$@ perllib.c diff --git a/win32/perlhost.h b/win32/perlhost.h index 57f4e31b2c..a417f6651e 100644 --- a/win32/perlhost.h +++ b/win32/perlhost.h @@ -15,22 +15,13 @@ #include "vmem.h" #include "vdir.h" -#if !defined(PERL_OBJECT) START_EXTERN_C -#endif extern char * g_win32_get_privlib(const char *pl); extern char * g_win32_get_sitelib(const char *pl); extern char * g_win32_get_vendorlib(const char *pl); extern char * g_getlogin(void); extern int do_spawn2(char *cmd, int exectype); -#if !defined(PERL_OBJECT) END_EXTERN_C -#endif - -#ifdef PERL_OBJECT -extern int g_do_aspawn(void *vreally, void **vmark, void **vsp); -#define do_aspawn g_do_aspawn -#endif class CPerlHost { @@ -1248,7 +1239,7 @@ PerlSockGethostbyname(struct IPerlSock* piPerl, const char* name) struct hostent* PerlSockGethostent(struct IPerlSock* piPerl) { - dTHXo; + dTHX; Perl_croak(aTHX_ "gethostent not implemented!\n"); return NULL; } @@ -1423,7 +1414,7 @@ PerlSockSocket(struct IPerlSock* piPerl, int af, int type, int protocol) int PerlSockSocketpair(struct IPerlSock* piPerl, int domain, int type, int protocol, int* fds) { - dTHXo; + dTHX; Perl_croak(aTHX_ "socketpair not implemented!\n"); return 0; } @@ -1575,7 +1566,7 @@ PerlProcKill(struct IPerlProc* piPerl, int pid, int sig) int PerlProcKillpg(struct IPerlProc* piPerl, int pid, int sig) { - dTHXo; + dTHX; Perl_croak(aTHX_ "killpg not implemented!\n"); return 0; } @@ -1589,7 +1580,7 @@ PerlProcPauseProc(struct IPerlProc* piPerl) PerlIO* PerlProcPopen(struct IPerlProc* piPerl, const char *command, const char *mode) { - dTHXo; + dTHX; PERL_FLUSHALL_FOR_CHILD; return win32_popen(command, mode); } @@ -1597,7 +1588,7 @@ PerlProcPopen(struct IPerlProc* piPerl, const char *command, const char *mode) PerlIO* PerlProcPopenList(struct IPerlProc* piPerl, const char *mode, IV narg, SV **args) { - dTHXo; + dTHX; PERL_FLUSHALL_FOR_CHILD; return win32_popenlist(mode, narg, args); } @@ -1663,9 +1654,6 @@ win32_start_child(LPVOID arg) PerlInterpreter *my_perl = (PerlInterpreter*)arg; GV *tmpgv; int status; -#ifdef PERL_OBJECT - CPerlObj *pPerl = (CPerlObj*)my_perl; -#endif #ifdef PERL_SYNC_FORK static long sync_fork_id = 0; long id = ++sync_fork_id; @@ -1760,7 +1748,7 @@ restart: int PerlProcFork(struct IPerlProc* piPerl) { - dTHXo; + dTHX; #ifdef USE_ITHREADS DWORD id; HANDLE handle; @@ -1771,7 +1759,7 @@ PerlProcFork(struct IPerlProc* piPerl) return -1; } h = new CPerlHost(*(CPerlHost*)w32_internal_host); - PerlInterpreter *new_perl = perl_clone_using((PerlInterpreter*)aTHXo, 1, + PerlInterpreter *new_perl = perl_clone_using((PerlInterpreter*)aTHX, 1, h->m_pHostperlMem, h->m_pHostperlMemShared, h->m_pHostperlMemParse, @@ -1785,7 +1773,7 @@ PerlProcFork(struct IPerlProc* piPerl) new_perl->Isys_intern.internal_host = h; # ifdef PERL_SYNC_FORK id = win32_start_child((LPVOID)new_perl); - PERL_SET_THX(aTHXo); + PERL_SET_THX(aTHX); # else # ifdef USE_RTL_THREAD_API handle = (HANDLE)_beginthreadex((void*)NULL, 0, win32_start_child, @@ -1794,7 +1782,7 @@ PerlProcFork(struct IPerlProc* piPerl) handle = CreateThread(NULL, 0, win32_start_child, (LPVOID)new_perl, 0, &id); # endif - PERL_SET_THX(aTHXo); /* XXX perl_clone*() set TLS */ + PERL_SET_THX(aTHX); /* XXX perl_clone*() set TLS */ if (!handle) { errno = EAGAIN; return -1; @@ -1861,7 +1849,7 @@ PerlProcASpawn(struct IPerlProc* piPerl, void *vreally, void **vmark, void **vsp int PerlProcLastHost(struct IPerlProc* piPerl) { - dTHXo; + dTHX; CPerlHost *h = (CPerlHost*)w32_internal_host; return h->LastHost(); } @@ -2138,7 +2126,7 @@ compare(const void *arg1, const void *arg2) void CPerlHost::Add(LPCSTR lpStr) { - dTHXo; + dTHX; char szBuffer[1024]; LPSTR *lpPtr; int index, length = strlen(lpStr)+1; @@ -2181,14 +2169,14 @@ CPerlHost::CalculateEnvironmentSpace(void) void CPerlHost::FreeLocalEnvironmentStrings(LPSTR lpStr) { - dTHXo; + dTHX; Safefree(lpStr); } char* CPerlHost::GetChildDir(void) { - dTHXo; + dTHX; int length; char* ptr; New(0, ptr, MAX_PATH+1, char); @@ -2206,14 +2194,14 @@ CPerlHost::GetChildDir(void) void CPerlHost::FreeChildDir(char* pStr) { - dTHXo; + dTHX; Safefree(pStr); } LPSTR CPerlHost::CreateLocalEnvironmentStrings(VDir &vDir) { - dTHXo; + dTHX; LPSTR lpStr, lpPtr, lpEnvPtr, lpTmp, lpLocalEnv, lpAllocPtr; DWORD dwSize, dwEnvIndex; int nLength, compVal; @@ -2302,7 +2290,7 @@ CPerlHost::CreateLocalEnvironmentStrings(VDir &vDir) void CPerlHost::Reset(void) { - dTHXo; + dTHX; if(m_lppEnvList != NULL) { for(DWORD index = 0; index < m_dwEnvCount; ++index) { Safefree(m_lppEnvList[index]); @@ -2315,7 +2303,7 @@ CPerlHost::Reset(void) void CPerlHost::Clearenv(void) { - dTHXo; + dTHX; char ch; LPSTR lpPtr, lpStr, lpEnvPtr; if (m_lppEnvList != NULL) { @@ -2355,7 +2343,7 @@ CPerlHost::Clearenv(void) char* CPerlHost::Getenv(const char *varname) { - dTHXo; + dTHX; if (w32_pseudo_id) { char *pEnv = Find(varname); if (pEnv && *pEnv) @@ -2367,7 +2355,7 @@ CPerlHost::Getenv(const char *varname) int CPerlHost::Putenv(const char *envstring) { - dTHXo; + dTHX; Add(envstring); if (!w32_pseudo_id) return win32_putenv(envstring); @@ -2378,7 +2366,7 @@ CPerlHost::Putenv(const char *envstring) int CPerlHost::Chdir(const char *dirname) { - dTHXo; + dTHX; int ret; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH]; diff --git a/win32/perllib.c b/win32/perllib.c index 2d5a87d141..6243a79fd3 100644 --- a/win32/perllib.c +++ b/win32/perllib.c @@ -5,10 +5,6 @@ #include "EXTERN.h" #include "perl.h" -#ifdef PERL_OBJECT -#define NO_XSLOCKS -#endif - #include "XSUB.h" #ifdef PERL_IMPLICIT_SYS @@ -23,10 +19,10 @@ char *staticlinkmodules[] = { NULL, }; -EXTERN_C void boot_DynaLoader (pTHXo_ CV* cv); +EXTERN_C void boot_DynaLoader (pTHX_ CV* cv); static void -xs_init(pTHXo) +xs_init(pTHX) { char *file = __FILE__; dXSUB_SYS; @@ -108,9 +104,6 @@ perl_alloc_override(struct IPerlMem** ppMem, struct IPerlMem** ppMemShared, pHost->m_pHostperlSock, pHost->m_pHostperlProc); if (my_perl) { -#ifdef PERL_OBJECT - CPerlObj* pPerl = (CPerlObj*)my_perl; -#endif w32_internal_host = pHost; } } @@ -133,9 +126,6 @@ perl_alloc(void) pHost->m_pHostperlSock, pHost->m_pHostperlProc); if (my_perl) { -#ifdef PERL_OBJECT - CPerlObj* pPerl = (CPerlObj*)my_perl; -#endif w32_internal_host = pHost; } } @@ -149,108 +139,6 @@ win32_delete_internal_host(void *h) delete host; } -#ifdef PERL_OBJECT - -EXTERN_C void -perl_construct(PerlInterpreter* my_perl) -{ - CPerlObj* pPerl = (CPerlObj*)my_perl; - try - { - Perl_construct(); - } - catch(...) - { - win32_fprintf(stderr, "%s\n", - "Error: Unable to construct data structures"); - perl_free(my_perl); - } -} - -EXTERN_C void -perl_destruct(PerlInterpreter* my_perl) -{ - CPerlObj* pPerl = (CPerlObj*)my_perl; -#ifdef DEBUGGING - Perl_destruct(); -#else - try - { - Perl_destruct(); - } - catch(...) - { - } -#endif -} - -EXTERN_C void -perl_free(PerlInterpreter* my_perl) -{ - CPerlObj* pPerl = (CPerlObj*)my_perl; - void *host = w32_internal_host; -#ifdef DEBUGGING - Perl_free(); -#else - try - { - Perl_free(); - } - catch(...) - { - } -#endif - win32_delete_internal_host(host); - PERL_SET_THX(NULL); -} - -EXTERN_C int -perl_run(PerlInterpreter* my_perl) -{ - CPerlObj* pPerl = (CPerlObj*)my_perl; - int retVal; -#ifdef DEBUGGING - retVal = Perl_run(); -#else - try - { - retVal = Perl_run(); - } - catch(...) - { - win32_fprintf(stderr, "Error: Runtime exception\n"); - retVal = -1; - } -#endif - return retVal; -} - -EXTERN_C int -perl_parse(PerlInterpreter* my_perl, void (*xsinit)(CPerlObj*), int argc, char** argv, char** env) -{ - int retVal; - CPerlObj* pPerl = (CPerlObj*)my_perl; -#ifdef DEBUGGING - retVal = Perl_parse(xsinit, argc, argv, env); -#else - try - { - retVal = Perl_parse(xsinit, argc, argv, env); - } - catch(...) - { - win32_fprintf(stderr, "Error: Parse exception\n"); - retVal = -1; - } -#endif - *win32_errno() = 0; - return retVal; -} - -#undef PL_perl_destruct_level -#define PL_perl_destruct_level int dummy - -#endif /* PERL_OBJECT */ #endif /* PERL_IMPLICIT_SYS */ EXTERN_C HANDLE w32_perldll_handle; @@ -295,23 +183,7 @@ RunPerl(int argc, char **argv, char **env) exitstatus = perl_parse(my_perl, xs_init, argc, argv, env); if (!exitstatus) { #if defined(TOP_CLONE) && defined(USE_ITHREADS) /* XXXXXX testing */ -# ifdef PERL_OBJECT - CPerlHost *h = new CPerlHost(); - new_perl = perl_clone_using(my_perl, 1, - h->m_pHostperlMem, - h->m_pHostperlMemShared, - h->m_pHostperlMemParse, - h->m_pHostperlEnv, - h->m_pHostperlStdIO, - h->m_pHostperlLIO, - h->m_pHostperlDir, - h->m_pHostperlSock, - h->m_pHostperlProc - ); - CPerlObj *pPerl = (CPerlObj*)new_perl; -# else new_perl = perl_clone(my_perl, 1); -# endif exitstatus = perl_run(new_perl); PERL_SET_THX(my_perl); #else @@ -400,7 +272,7 @@ DllMain(HANDLE hModule, /* DLL module handle */ #if defined(USE_ITHREADS) && defined(PERL_IMPLICIT_SYS) EXTERN_C PerlInterpreter * perl_clone_host(PerlInterpreter* proto_perl, UV flags) { - dTHXo; + dTHX; CPerlHost *h; h = new CPerlHost(*(CPerlHost*)PL_sys_intern.internal_host); proto_perl = perl_clone_using(proto_perl, flags, diff --git a/win32/win32.c b/win32/win32.c index 687f121c8f..905a987778 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -91,13 +91,6 @@ int _fcloseall(); # define getlogin g_getlogin #endif -#if defined(PERL_OBJECT) -# undef do_aspawn -# define do_aspawn g_do_aspawn -# undef Perl_do_exec -# define Perl_do_exec g_do_exec -#endif - static void get_shell(void); static long tokenize(const char *str, char **dest, char ***destv); int do_spawn2(char *cmd, int exectype); @@ -179,7 +172,7 @@ get_regstr_from(HKEY hkey, const char *valuename, SV **svp) if (retval == ERROR_SUCCESS && (type == REG_SZ || type == REG_EXPAND_SZ)) { - dTHXo; + dTHX; if (!*svp) *svp = sv_2mortal(newSVpvn("",0)); SvGROW(*svp, datalen); @@ -259,7 +252,7 @@ get_emd_part(SV **prev_pathp, char *trailing_path, ...) /* only add directory if it exists */ if (GetFileAttributes(mod_name) != (DWORD) -1) { /* directory exists */ - dTHXo; + dTHX; if (!*prev_pathp) *prev_pathp = sv_2mortal(newSVpvn("",0)); sv_catpvn(*prev_pathp, ";", 1); @@ -273,7 +266,7 @@ get_emd_part(SV **prev_pathp, char *trailing_path, ...) char * win32_get_privlib(const char *pl) { - dTHXo; + dTHX; char *stdlib = "lib"; char buffer[MAX_PATH+1]; SV *sv = Nullsv; @@ -290,7 +283,7 @@ win32_get_privlib(const char *pl) static char * win32_get_xlib(const char *pl, const char *xlib, const char *libname) { - dTHXo; + dTHX; char regstr[40]; char pathstr[MAX_PATH+1]; DWORD datalen; @@ -438,7 +431,7 @@ win32_getpid(void) { int pid; #ifdef USE_ITHREADS - dTHXo; + dTHX; if (w32_pseudo_id) return -((int)w32_pseudo_id); #endif @@ -464,7 +457,7 @@ tokenize(const char *str, char **dest, char ***destv) char **retvstart = 0; int items = -1; if (str) { - dTHXo; + dTHX; int slen = strlen(str); register char *ret; register char **retv; @@ -507,7 +500,7 @@ tokenize(const char *str, char **dest, char ***destv) static void get_shell(void) { - dTHXo; + dTHX; if (!w32_perlshell_tokens) { /* we don't use COMSPEC here for two reasons: * 1. the same reason perl on UNIX doesn't use SHELL--rampant and @@ -528,7 +521,7 @@ get_shell(void) int do_aspawn(void *vreally, void **vmark, void **vsp) { - dTHXo; + dTHX; SV *really = (SV*)vreally; SV **mark = (SV**)vmark; SV **sp = (SV**)vsp; @@ -596,7 +589,7 @@ do_aspawn(void *vreally, void **vmark, void **vsp) int do_spawn2(char *cmd, int exectype) { - dTHXo; + dTHX; char **a; char *s; char **argv; @@ -712,7 +705,7 @@ Perl_do_exec(pTHX_ char *cmd) DllExport DIR * win32_opendir(char *filename) { - dTHXo; + dTHX; DIR *dirp; long len; long idx; @@ -824,7 +817,7 @@ win32_readdir(DIR *dirp) /* Now set up for the next call to readdir */ dirp->curr += len + 1; if (dirp->curr >= dirp->end) { - dTHXo; + dTHX; char* ptr; BOOL res; WIN32_FIND_DATAW wFindData; @@ -898,7 +891,7 @@ win32_rewinddir(DIR *dirp) DllExport int win32_closedir(DIR *dirp) { - dTHXo; + dTHX; if (dirp->handle != INVALID_HANDLE_VALUE) FindClose(dirp->handle); Safefree(dirp->start); @@ -960,7 +953,7 @@ setgid(gid_t agid) char * getlogin(void) { - dTHXo; + dTHX; char *buf = w32_getlogin_buffer; DWORD size = sizeof(w32_getlogin_buffer); if (GetUserName(buf,&size)) @@ -1003,7 +996,7 @@ retry: static long find_pid(int pid) { - dTHXo; + dTHX; long child = w32_num_children; while (--child >= 0) { if (w32_child_pids[child] == pid) @@ -1016,7 +1009,7 @@ static void remove_dead_process(long child) { if (child >= 0) { - dTHXo; + dTHX; CloseHandle(w32_child_handles[child]); Move(&w32_child_handles[child+1], &w32_child_handles[child], (w32_num_children-child-1), HANDLE); @@ -1030,7 +1023,7 @@ remove_dead_process(long child) static long find_pseudo_pid(int pid) { - dTHXo; + dTHX; long child = w32_num_pseudo_children; while (--child >= 0) { if (w32_pseudo_child_pids[child] == pid) @@ -1043,7 +1036,7 @@ static void remove_dead_pseudo_process(long child) { if (child >= 0) { - dTHXo; + dTHX; CloseHandle(w32_pseudo_child_handles[child]); Move(&w32_pseudo_child_handles[child+1], &w32_pseudo_child_handles[child], (w32_num_pseudo_children-child-1), HANDLE); @@ -1057,7 +1050,7 @@ remove_dead_pseudo_process(long child) DllExport int win32_kill(int pid, int sig) { - dTHXo; + dTHX; HANDLE hProcess; long child; #ifdef USE_ITHREADS @@ -1123,7 +1116,7 @@ win32_sleep(unsigned int t) DllExport int win32_stat(const char *path, struct stat *sbuf) { - dTHXo; + dTHX; char buffer[MAX_PATH+1]; int l = strlen(path); int res; @@ -1325,7 +1318,7 @@ win32_longpath(char *path) DllExport char * win32_getenv(const char *name) { - dTHXo; + dTHX; WCHAR wBuffer[MAX_PATH+1]; DWORD needlen; SV *curitem = Nullsv; @@ -1374,7 +1367,7 @@ win32_getenv(const char *name) DllExport int win32_putenv(const char *name) { - dTHXo; + dTHX; char* curitem; char* val; WCHAR* wCuritem; @@ -1483,7 +1476,7 @@ filetime_from_time(PFILETIME pFileTime, time_t Time) DllExport int win32_unlink(const char *filename) { - dTHXo; + dTHX; int ret; DWORD attrs; @@ -1528,7 +1521,7 @@ fail: DllExport int win32_utime(const char *filename, struct utimbuf *times) { - dTHXo; + dTHX; HANDLE handle; FILETIME ftCreate; FILETIME ftAccess; @@ -1677,7 +1670,7 @@ win32_uname(struct utsname *name) DllExport int win32_waitpid(int pid, int *status, int flags) { - dTHXo; + dTHX; DWORD timeout = (flags & WNOHANG) ? 0 : INFINITE; int retval = -1; long child; @@ -1761,7 +1754,7 @@ win32_wait(int *status) /* XXX this wait emulation only knows about processes * spawned via win32_spawnvp(P_NOWAIT, ...). */ - dTHXo; + dTHX; int i, retval; DWORD exitcode, waitcode; @@ -1816,23 +1809,19 @@ FAILED: return -1; } -#ifndef PERL_OBJECT - static UINT timerid = 0; static VOID CALLBACK TimerProc(HWND win, UINT msg, UINT id, DWORD time) { - dTHXo; + dTHX; KillTimer(NULL,timerid); timerid=0; CALL_FPTR(PL_sighandlerp)(14); } -#endif /* !PERL_OBJECT */ DllExport unsigned int win32_alarm(unsigned int sec) { -#ifndef PERL_OBJECT /* * the 'obvious' implentation is SetTimer() with a callback * which does whatever receiving SIGALRM would do @@ -1842,7 +1831,7 @@ win32_alarm(unsigned int sec) * Snag is unless something is looking at the message queue * nothing happens :-( */ - dTHXo; + dTHX; if (sec) { timerid = SetTimer(NULL,timerid,sec*1000,(TIMERPROC)TimerProc); @@ -1857,7 +1846,6 @@ win32_alarm(unsigned int sec) timerid=0; } } -#endif /* !PERL_OBJECT */ return 0; } @@ -1868,7 +1856,7 @@ extern char * des_fcrypt(const char *txt, const char *salt, char *cbuf); DllExport char * win32_crypt(const char *txt, const char *salt) { - dTHXo; + dTHX; #ifdef HAVE_DES_FCRYPT return des_fcrypt(txt, salt, w32_crypt_buffer); #else @@ -1980,7 +1968,7 @@ win32_flock(int fd, int oper) HANDLE fh; if (!IsWinNT()) { - dTHXo; + dTHX; Perl_croak_nocontext("flock() unimplemented on this platform"); return -1; } @@ -2079,7 +2067,7 @@ win32_strerror(int e) DWORD source = 0; if (e < 0 || e > sys_nerr) { - dTHXo; + dTHX; if (e < 0) e = GetLastError(); @@ -2119,7 +2107,7 @@ win32_str_os_error(void *sv, DWORD dwErr) dwErr, GetLastError()); } if (sMsg) { - dTHXo; + dTHX; sv_setpvn((SV*)sv, sMsg, dwLen); LocalFree(sMsg); } @@ -2172,7 +2160,7 @@ win32_fwrite(const void *buf, size_t size, size_t count, FILE *fp) DllExport FILE * win32_fopen(const char *filename, const char *mode) { - dTHXo; + dTHX; WCHAR wMode[MODE_SIZE], wBuffer[MAX_PATH+1]; FILE *f; @@ -2203,7 +2191,7 @@ win32_fopen(const char *filename, const char *mode) DllExport FILE * win32_fdopen(int handle, const char *mode) { - dTHXo; + dTHX; WCHAR wMode[MODE_SIZE]; FILE *f; if (USING_WIDE()) { @@ -2221,7 +2209,7 @@ win32_fdopen(int handle, const char *mode) DllExport FILE * win32_freopen(const char *path, const char *mode, FILE *stream) { - dTHXo; + dTHX; WCHAR wMode[MODE_SIZE], wBuffer[MAX_PATH+1]; if (stricmp(path, "/dev/null")==0) path = "NUL"; @@ -2425,7 +2413,7 @@ win32_popen(const char *command, const char *mode) /* start the child */ { - dTHXo; + dTHX; if ((childpid = do_spawn_nowait((char*)command)) == -1) goto cleanup; @@ -2470,7 +2458,7 @@ win32_pclose(PerlIO *pf) #ifdef USE_RTL_POPEN return _pclose(pf); #else - dTHXo; + dTHX; int childpid, status; SV *sv; @@ -2564,7 +2552,7 @@ Nt4CreateHardLinkW( DllExport int win32_link(const char *oldname, const char *newname) { - dTHXo; + dTHX; BOOL (__stdcall *pfnCreateHardLinkW)(LPCWSTR,LPCWSTR,LPSECURITY_ATTRIBUTES); WCHAR wOldName[MAX_PATH+1]; WCHAR wNewName[MAX_PATH+1]; @@ -2597,7 +2585,7 @@ win32_rename(const char *oname, const char *newname) char szOldName[MAX_PATH+1]; char szNewName[MAX_PATH+1]; BOOL bResult; - dTHXo; + dTHX; /* XXX despite what the documentation says about MoveFileEx(), * it doesn't work under Windows95! @@ -2735,7 +2723,7 @@ win32_tell(int fd) DllExport int win32_open(const char *path, int flag, ...) { - dTHXo; + dTHX; va_list ap; int pmode; WCHAR wBuffer[MAX_PATH+1]; @@ -2996,7 +2984,7 @@ win32_write(int fd, const void *buf, unsigned int cnt) DllExport int win32_mkdir(const char *dir, int mode) { - dTHXo; + dTHX; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH+1]; A2WHELPER(dir, wBuffer, sizeof(wBuffer)); @@ -3008,7 +2996,7 @@ win32_mkdir(const char *dir, int mode) DllExport int win32_rmdir(const char *dir) { - dTHXo; + dTHX; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH+1]; A2WHELPER(dir, wBuffer, sizeof(wBuffer)); @@ -3020,7 +3008,7 @@ win32_rmdir(const char *dir) DllExport int win32_chdir(const char *dir) { - dTHXo; + dTHX; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH+1]; A2WHELPER(dir, wBuffer, sizeof(wBuffer)); @@ -3032,7 +3020,7 @@ win32_chdir(const char *dir) DllExport int win32_access(const char *path, int mode) { - dTHXo; + dTHX; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH+1]; A2WHELPER(path, wBuffer, sizeof(wBuffer)); @@ -3044,7 +3032,7 @@ win32_access(const char *path, int mode) DllExport int win32_chmod(const char *path, int mode) { - dTHXo; + dTHX; if (USING_WIDE()) { WCHAR wBuffer[MAX_PATH+1]; A2WHELPER(path, wBuffer, sizeof(wBuffer)); @@ -3057,7 +3045,7 @@ win32_chmod(const char *path, int mode) static char * create_command_line(const char* command, const char * const *args) { - dTHXo; + dTHX; int index; char *cmd, *ptr, *arg; STRLEN len = strlen(command) + 1; @@ -3081,7 +3069,7 @@ create_command_line(const char* command, const char * const *args) static char * qualified_path(const char *cmd) { - dTHXo; + dTHX; char *pathstr; char *fullcmd, *curfullcmd; STRLEN cmdlen = 0; @@ -3186,7 +3174,7 @@ free_childenv(void* d) char* get_childdir(void) { - dTHXo; + dTHX; char* ptr; char szfilename[(MAX_PATH+1)*2]; if (USING_WIDE()) { @@ -3206,7 +3194,7 @@ get_childdir(void) void free_childdir(char* d) { - dTHXo; + dTHX; Safefree(d); } @@ -3228,7 +3216,7 @@ win32_spawnvp(int mode, const char *cmdname, const char *const *argv) #ifdef USE_RTL_SPAWNVP return spawnvp(mode, cmdname, (char * const *)argv); #else - dTHXo; + dTHX; int ret; void* env; char* dir; @@ -3348,7 +3336,7 @@ DllExport int win32_execv(const char *cmdname, const char *const *argv) { #ifdef USE_ITHREADS - dTHXo; + dTHX; /* if this is a pseudo-forked child, we just want to spawn * the new program, and return */ if (w32_pseudo_id) @@ -3361,7 +3349,7 @@ DllExport int win32_execvp(const char *cmdname, const char *const *argv) { #ifdef USE_ITHREADS - dTHXo; + dTHX; /* if this is a pseudo-forked child, we just want to spawn * the new program, and return */ if (w32_pseudo_id) { @@ -3572,7 +3560,7 @@ win32_get_osfhandle(int fd) DllExport void* win32_dynaload(const char* filename) { - dTHXo; + dTHX; HMODULE hModule; char buf[MAX_PATH+1]; char *first; @@ -4065,7 +4053,7 @@ XS(w32_CopyFile) void Perl_init_os_extras(void) { - dTHXo; + dTHX; char *file = __FILE__; dXSUB_SYS; @@ -4128,16 +4116,6 @@ win32_get_child_IO(child_IO_table* ptbl) #ifdef HAVE_INTERP_INTERN -# ifdef PERL_OBJECT -# undef Perl_sys_intern_init -# define Perl_sys_intern_init CPerlObj::Perl_sys_intern_init -# undef Perl_sys_intern_dup -# define Perl_sys_intern_dup CPerlObj::Perl_sys_intern_dup -# undef Perl_sys_intern_clear -# define Perl_sys_intern_clear CPerlObj::Perl_sys_intern_clear -# define pPerl this -# endif - void Perl_sys_intern_init(pTHX) { @@ -4184,13 +4162,8 @@ Perl_sys_intern_dup(pTHX_ struct interp_intern *src, struct interp_intern *dst) # endif /* USE_ITHREADS */ #endif /* HAVE_INTERP_INTERN */ -#ifdef PERL_OBJECT -# undef this -# define this pPerl -#endif - static void -win32_free_argvw(pTHXo_ void *ptr) +win32_free_argvw(pTHX_ void *ptr) { char** argv = (char**)ptr; while(*argv) { @@ -4202,7 +4175,7 @@ win32_free_argvw(pTHXo_ void *ptr) void win32_argv2utf8(int argc, char** argv) { - dTHXo; + dTHX; char* psz; int length, wargc; LPWSTR* lpwStr = CommandLineToArgvW(GetCommandLineW(), &wargc); diff --git a/win32/win32.h b/win32/win32.h index 1350670690..16ad7fa195 100644 --- a/win32/win32.h +++ b/win32/win32.h @@ -13,7 +13,7 @@ # define _WIN32_WINNT 0x0400 /* needed for TryEnterCriticalSection() etc. */ #endif -#if defined(PERL_OBJECT) || defined(PERL_IMPLICIT_SYS) || defined(PERL_CAPI) +#if defined(PERL_IMPLICIT_SYS) # define DYNAMIC_ENV_FETCH # define HAS_GETENV_LEN # define prime_env_iter() @@ -42,16 +42,12 @@ /* now even GCC supports __declspec() */ -#if defined(PERL_OBJECT) -#define DllExport -#else #if defined(PERLDLL) || defined(WIN95FIX) #define DllExport /*#define DllExport __declspec(dllexport)*/ /* noises with VC5+sp3 */ #else #define DllExport __declspec(dllimport) #endif -#endif #define WIN32_LEAN_AND_MEAN #include <windows.h> @@ -186,11 +182,6 @@ struct utsname { #pragma warn -use /* "'foo' is declared but never used" */ #pragma warn -csu /* "comparing signed and unsigned values" */ -/* Borland is picky about a bare member function name used as its ptr */ -#ifdef PERL_OBJECT -# define MEMBER_TO_FPTR(name) &(name) -#endif - /* Borland C thinks that a pointer to a member variable is 12 bytes in size. */ #define PERL_MEMBER_PTR_SIZE 12 @@ -223,10 +214,6 @@ typedef long gid_t; #define fcloseall _fcloseall #define isnan _isnan /* ...same libraries as MSVC */ -#ifdef PERL_OBJECT -# define MEMBER_TO_FPTR(name) &(name) -#endif - #ifndef _O_NOINHERIT # define _O_NOINHERIT 0x0080 # ifndef _NO_OLDNAMES @@ -243,46 +230,6 @@ typedef long gid_t; /* compatibility stuff for other compilers goes here */ - -#if !defined(PERL_OBJECT) && defined(PERL_CAPI) && defined(PERL_MEMBER_PTR_SIZE) -# define STRUCT_MGVTBL_DEFINITION \ -struct mgvtbl { \ - union { \ - int (CPERLscope(*svt_get))(pTHX_ SV *sv, MAGIC* mg); \ - char handle_VC_problem1[PERL_MEMBER_PTR_SIZE]; \ - }; \ - union { \ - int (CPERLscope(*svt_set))(pTHX_ SV *sv, MAGIC* mg); \ - char handle_VC_problem2[PERL_MEMBER_PTR_SIZE]; \ - }; \ - union { \ - U32 (CPERLscope(*svt_len))(pTHX_ SV *sv, MAGIC* mg); \ - char handle_VC_problem3[PERL_MEMBER_PTR_SIZE]; \ - }; \ - union { \ - int (CPERLscope(*svt_clear))(pTHX_ SV *sv, MAGIC* mg); \ - char handle_VC_problem4[PERL_MEMBER_PTR_SIZE]; \ - }; \ - union { \ - int (CPERLscope(*svt_free))(pTHX_ SV *sv, MAGIC* mg); \ - char handle_VC_problem5[PERL_MEMBER_PTR_SIZE]; \ - }; \ -} - -# define BASEOP_DEFINITION \ - OP* op_next; \ - OP* op_sibling; \ - OP* (CPERLscope(*op_ppaddr))(pTHX); \ - char handle_VC_problem[PERL_MEMBER_PTR_SIZE-sizeof(OP*)]; \ - PADOFFSET op_targ; \ - OPCODE op_type; \ - U16 op_seq; \ - U8 op_flags; \ - U8 op_private; - -#endif /* !PERL_OBJECT && PERL_CAPI && PERL_MEMBER_PTR_SIZE */ - - START_EXTERN_C /* For UNIX compatibility. */ diff --git a/win32/win32sck.c b/win32/win32sck.c index bdc335f4fc..4fb20473b4 100644 --- a/win32/win32sck.c +++ b/win32/win32sck.c @@ -19,11 +19,6 @@ #include "EXTERN.h" #include "perl.h" -#if defined(PERL_OBJECT) -#define NO_XSLOCKS -#include "XSUB.h" -#endif - #include "Win32iop.h" #include <sys/socket.h> #include <fcntl.h> @@ -82,7 +77,7 @@ EndSockets(void) void start_sockets(void) { - dTHXo; + dTHX; unsigned short version; WSADATA retdata; int ret; @@ -106,7 +101,7 @@ set_socktype(void) { #ifdef USE_SOCKETS_AS_HANDLES #if defined(USE_5005THREADS) || defined(USE_ITHREADS) - dTHXo; + dTHX; if (!w32_init_socktype) { #endif int iSockOpt = SO_SYNCHRONOUS_NONALERT; @@ -572,7 +567,7 @@ win32_getprotobynumber(int num) struct servent * win32_getservbyname(const char *name, const char *proto) { - dTHXo; + dTHX; struct servent *r; SOCKET_TEST(r = getservbyname(name, proto), NULL); @@ -585,7 +580,7 @@ win32_getservbyname(const char *name, const char *proto) struct servent * win32_getservbyport(int port, const char *proto) { - dTHXo; + dTHX; struct servent *r; SOCKET_TEST(r = getservbyport(port, proto), NULL); @@ -598,7 +593,7 @@ win32_getservbyport(int port, const char *proto) int win32_ioctl(int i, unsigned int u, char *data) { - dTHXo; + dTHX; u_long argp = (u_long)data; int retval; @@ -639,28 +634,28 @@ win32_inet_addr(const char FAR *cp) void win32_endhostent() { - dTHXo; + dTHX; Perl_croak_nocontext("endhostent not implemented!\n"); } void win32_endnetent() { - dTHXo; + dTHX; Perl_croak_nocontext("endnetent not implemented!\n"); } void win32_endprotoent() { - dTHXo; + dTHX; Perl_croak_nocontext("endprotoent not implemented!\n"); } void win32_endservent() { - dTHXo; + dTHX; Perl_croak_nocontext("endservent not implemented!\n"); } @@ -668,7 +663,7 @@ win32_endservent() struct netent * win32_getnetent(void) { - dTHXo; + dTHX; Perl_croak_nocontext("getnetent not implemented!\n"); return (struct netent *) NULL; } @@ -676,7 +671,7 @@ win32_getnetent(void) struct netent * win32_getnetbyname(char *name) { - dTHXo; + dTHX; Perl_croak_nocontext("getnetbyname not implemented!\n"); return (struct netent *)NULL; } @@ -684,7 +679,7 @@ win32_getnetbyname(char *name) struct netent * win32_getnetbyaddr(long net, int type) { - dTHXo; + dTHX; Perl_croak_nocontext("getnetbyaddr not implemented!\n"); return (struct netent *)NULL; } @@ -692,7 +687,7 @@ win32_getnetbyaddr(long net, int type) struct protoent * win32_getprotoent(void) { - dTHXo; + dTHX; Perl_croak_nocontext("getprotoent not implemented!\n"); return (struct protoent *) NULL; } @@ -700,7 +695,7 @@ win32_getprotoent(void) struct servent * win32_getservent(void) { - dTHXo; + dTHX; Perl_croak_nocontext("getservent not implemented!\n"); return (struct servent *) NULL; } @@ -708,7 +703,7 @@ win32_getservent(void) void win32_sethostent(int stayopen) { - dTHXo; + dTHX; Perl_croak_nocontext("sethostent not implemented!\n"); } @@ -716,7 +711,7 @@ win32_sethostent(int stayopen) void win32_setnetent(int stayopen) { - dTHXo; + dTHX; Perl_croak_nocontext("setnetent not implemented!\n"); } @@ -724,7 +719,7 @@ win32_setnetent(int stayopen) void win32_setprotoent(int stayopen) { - dTHXo; + dTHX; Perl_croak_nocontext("setprotoent not implemented!\n"); } @@ -732,7 +727,7 @@ win32_setprotoent(int stayopen) void win32_setservent(int stayopen) { - dTHXo; + dTHX; Perl_croak_nocontext("setservent not implemented!\n"); } diff --git a/win32/win32thread.c b/win32/win32thread.c index 6df2768c77..1fdd0efc02 100644 --- a/win32/win32thread.c +++ b/win32/win32thread.c @@ -1,12 +1,6 @@ #include "EXTERN.h" #include "perl.h" -#if defined(PERL_OBJECT) -#define NO_XSLOCKS -extern CPerlObj* pPerl; -#include "XSUB.h" -#endif - #ifdef USE_DECLSPEC_THREAD __declspec(thread) void *PL_current_context = NULL; #endif |