summaryrefslogtreecommitdiff
path: root/win32/win32sck.c
Commit message (Collapse)AuthorAgeFilesLines
* more dTHX optimizations in /win32/*Daniel Dragan2012-12-051-2/+4
| | | | | | | | | | In some places, where there is a higher risk of a NULL my_perl happening at an unknown point in the future IMO new scopes were created. In other places dTHXa(NULL) and aTHXa were used to avoid large whitespace changes. win32_rename and win32_getenv I determined would have no benefit from changing them. More context passing was added to static funcs called by win32_kill and win32_waitpid removing the need to move the dTHXs in the 2 funcs.
* remove unused dTHXes in /win32/*Daniel Dragan2012-11-081-1/+0
| | | | | | Remove dTHXes in win32 perl funcs where they were not used, or could be replaced with nocontext croaks/warns. Since Perl_get_context is a function it is not optimized away by the compiler.
* create aTHXa, some unused dTHXs removed in /win32/*Daniel Dragan2012-11-081-1/+0
| | | | | | | | | dTHXes that were unused, or because Newx/Safefree were the only things called were removed. In some places the dTHX turned into dTHXa and aTHXa so the context is not fetched until it is actually used (locality/frees a C stack slot or frees a non-volatile register). Also see http://www.nntp.perl.org/group/perl.perl5.porters/2012/10/msg194414.html and http://www.nntp.perl.org/group/perl.perl5.porters/2012/10/msg194861.html
* "func not implemented" croaks optimizations in /win32/*Daniel Dragan2012-11-081-26/+13
| | | | | | | | | This commit removes a number of "* not implemented" strings from the image. A win32_croak_not_implemented wrapper is created to reduce machine code by not putting the format string on the C stack many times. embed.fnc was used to declare win32_croak_not_implemented for proper cross compiler support of noreturn (noreturn on GCC and VC ok). Tailcalling and noreturn optimizations of the C compiler are heavily used in this commit.
* Win32 miniperl: delay loading for Winsock, and then remove itDaniel Dragan2012-10-311-0/+19
| | | | | | | | | | | | | | | | | | | Slim down the image and speed up start up time for Win32 miniperl by removing Winsock. Also if the build process on Win32 in the future requires sockets, commenting one line in win32.h will turn sockets back on for miniperl, but this time with delay loading on VC Perl. The only casulty of no sockets for Win32 miniperl was figuring out the computer's name in win32/config_sh.PL. A workaround by using an ENV var was implemented. The purpose of this commit is to speed up the build process of Perl. As said in the comment in win32.h, the WIN32_NO_SOCKETS macro is incomplete in implementation. It is only removed winsock from being linked in in miniperl, not full Perl. PERL_IMPLICIT_SYS (specifically PerlSock in win32/perlhost.h) and makedef.pl's hard coded list of win32_* function exports cause winsock to still be linked in with even with WIN32_NO_SOCKETS on full perl. Both PERL_IMPLICIT_SYS (win32/perlhost.h) and makedef.pl would require changes to remove winsock from being linked in on full perl in the future.
* Remove option to build without USE_SOCKETS_AS_HANDLES on WindowsSteve Hay2012-09-281-61/+3
| | | | | | | | | The option is always defined by default and can't be disabled from the makefiles. Manually disabling it causes several tests to fail, which nobody has reported, so we presume nobody does this. The non-default configuration is believed to be historical cruft with no value now, and has clearly bitrotted in recent years (hence the test failures), so remove it to simplify the codebase slightly.
* The Borland Chainsaw MassacreSteve Hay2011-09-101-2/+0
| | | | | Remove support for the Borland C++ compiler on Win32, as agreed here: http://www.xray.mpe.mpg.de/mailing-lists/perl5-porters/2011-09/msg00034.html
* Get rid of PERL_MSVCRT_READFIXJan Dubois2010-12-061-6/+0
| | | | | | | The code works around a bug in very old versions of MSVCRT.dll. The issue has been fixed a long time ago by Microsoft, so anyone who has installed a Windows Service Pack in the last 10 years or so won't be affected by the problem.
* Windows 95 Chainsaw MassacreJan Dubois2010-12-021-58/+2
| | | | | Remove all supporting code for Windows 9x and Windows NT. The minimum supported version is Windows 2000 now.
* The winsock select() implementation doesn't support all empty 'fd_set's.Jan Dubois2009-10-131-11/+16
| | | | | | | | | | | The code already contained a workaround for the special case select(undef, undef, undef, $sleep); but didn't handle the case when actual bit vectors were passed in that didn't have any bits set. Fixes http://rt.perl.org/rt3/Public/Bug/Display.html?id=54544
* Remove broken links for hip communications inc.Leon Brocard2009-09-131-1/+1
|
* select() generates "Invalid parameter" messages on Windows Vista.Jan Dubois2009-05-131-11/+24
| | | | | | | | | | | | | | | | | | | | | The messages are generated by OutputDebugString() so are only visible inside a debugger, or other debugger viewer applications. The messages are generated by the _get_osfhandle() calls with invalid file ids. This change makes sure it is only called when the corresponding bit in the select() arguments has been set. Related bug reports: http://bugs.activestate.com/show_bug.cgi?id=82995 http://bugs.slimdevices.com/show_bug.cgi?id=11896 http://getpopfile.org/ticket/45 Even with this patch there are still residual "Invalid parameter" messages in the debug output while building Perl itself. They are generated by miniperl in the win32_fclose() function, again calling _get_osfhandle() with an invalid handle. The same messages can be observed when Perl is built *without* USE_PERLIO (just like miniperl).
* [perl #46309] Buffer overflow in win32_select() (PATCH included) Risto Kankkunen2008-06-171-22/+8
| | | | | | From: Risto Kankkunen (via RT) <perlbug-followup@perl.org> Message-ID: <rt-3.6.HEAD-10743-1192009453-1788.46309-75-0@perl.org> p4raw-id: //depot/perl@34067
* [PATCH] Remove dead code from win32/win32sck.cJan Dubois2007-06-261-17/+0
| | | | | | | | | | | | From: "Jan Dubois" <jand@activestate.com> Date: Mon, 25 Jun 2007 17:13:04 -0700 Message-ID: <02bb01c7b786$c42099c0$4c61cd40$@com> Subject: RE: [PATCH] Remove dead code from win32/win32sck.c From: "Jan Dubois" <jand@activestate.com> Date: Mon, 25 Jun 2007 17:26:15 -0700 Message-ID: <02c801c7b788$9bf7ebe0$d3e7c3a0$@com> p4raw-id: //depot/perl@31469
* Re: Net::SMTP can't send large messages with bleadperlYves Orton2007-06-201-3/+7
| | | | | Message-ID: <9b18b3110706200622o344c417apbd50468c6e5eb533@mail.gmail.com> p4raw-id: //depot/perl@31426
* Re: janitorial work ? [patch]Jim Cromie2005-07-081-2/+2
| | | | | | | | Message-ID: <42CC3CE9.5050606@divsol.com> (reverted all dual-lived modules since they must work with older perls too so must wait for a new Devel::PPPort) p4raw-id: //depot/perl@25101
* Fix bug #33664: allow for transport providers with protocol == 0Steve Hay2005-04-181-1/+2
| | | | | | (This indicates that any protocol may be used, so don't bother checking that the requested protocol matches in this case.) p4raw-id: //depot/perl@24242
* A couple more Win32 compilation clean-upsSteve Hay2005-03-301-3/+3
| | | p4raw-id: //depot/perl@24099
* Implement new environment variable to allow the use of non-IFSSteve Hay2004-09-061-0/+5
| | | | | | | | | compatible LSP's on Windows to allow Perl to work in conjunction with a firewall such as McAfee Guardian. Bug report and possible solutions by Ken Fox <kfox@ford.com>; further assistance by Artiom Morozov <artiom@phreaker.net>. p4raw-id: //depot/perl@23275
* Fix [perl #24269] socket() call uses non-IFS providersSteve Hay2004-08-061-19/+65
| | | | | | | | causing subsequent print/read to hang or misbehave Patch supplied by Artiom Morozov <artiom@phreaker.net> in the bug report at http://rt.perl.org/rt3/index.html?q=24269 p4raw-id: //depot/perl@23200
* 5.8.1 / bcc55 / win32 / Enable PerlIO and/ or USE_LARGE_FILESNigel Sandever2003-12-281-0/+8
| | | | | | | From: "Nigel Sandever" <njsandever@hotmail.com> Message-ID: <Law9-F94BdsnvUFcxT500000ea5@hotmail.com> Date: Thu, 25 Sep 2003 21:49:07 +0000 p4raw-id: //depot/perl@21989
* missing init in change#19533Gurusamy Sarathy2003-05-171-1/+1
| | | | | p4raw-link: @19533 on //depot/perl: 1c8780751e85c3ece441fc8ecdff2f1dc99f9906 p4raw-id: //depot/perl@19537
* avoid select() on windows destroying errno (used to typicallyGurusamy Sarathy2003-05-171-1/+4
| | | | | always sets it to EINVAL due to the way it maps the FD_SETs) p4raw-id: //depot/perl@19533
* Happy chainsaw stories; The removal of the 5005 threadsH.Merijn Brand2002-10-191-3/+3
| | | | | Still imcomplete. Configure will follow p4raw-id: //depot/perl@18030
* fixes for all the warnings reported by Visual C (most of thisGurusamy Sarathy2002-04-211-1/+1
| | | | | | change is from change#12026) p4raw-link: @12026 on //depot/maint-5.6/perl: ff42b73b40f5a895aef4bed81c794f468e0609bc p4raw-id: //depot/perl@16048
* Windows 64-bit support:Gurusamy Sarathy2002-04-211-3/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | * support for building it in the regular makefiles * large files support via the _*i64() functions (this should be portable to the 32-bit universe too, but quite untested and and binary-incompatible, therefore not enabled there) * three additional test failures in addition to the t/end.t one (see README.win32) * sprintf() on Windows gets %I{32,64,}[xoud] format that parallel the ones available from the CRT (needed because Perl uses the UVxf macros in both sprintf() *and* in sv_catpvf() et al.) * add a few 64-bit notes to README.win32 The following general problems were also fixed: * s/struct stat/Stat_t/g * Data::Dumper had some naughty 'long' typecasts * Errno_pm.PL didn't work safe when winsock.h was not in the same directory as errno.h * various tell/seek things were incorrectly prototyped * squelch ugly looking noise when running tests * Embed.t wasn't linking in all the libraries * perl57.dll is now perl58.dll (anticipating 5.8.0-RC1) * re-enable all the disabled warnings (additional fixes may be needed for the warnings uncovered by this) p4raw-id: //depot/perl@16033
* remove deprecated PERL_OBJECT cruft, it has long since stoppedGurusamy Sarathy2001-08-311-23/+18
| | | | | working in 5.7.x p4raw-id: //depot/perl@11803
* Changes USE_THREADS to USE_5005THREADS in the entire source.Artur Bergman2001-08-271-3/+3
| | | | | | Thanks to H. Merijn Brand for the patch. Some of the comments and or guards might be removable in perl.h now. p4raw-id: //depot/perl@11758
* Borland C++ for Win32 fixes; perl@9359 (also perl@9424)Vadim Konovalov2001-03-291-0/+4
| | | | | Message-ID: <001c01c0b7d1$463dd880$5742983e@vad> p4raw-id: //depot/perl@9427
* fix open(FOO, ">&MYSOCK") failure under Windows 9x (problem isGurusamy Sarathy2000-12-051-0/+35
| | | | | | due to the notorious GetFileType() bug in Windows 9x, which fstat() tickles) p4raw-id: //depot/perl@7986
* Configure GCC/Win32 build -DuseperlioNick Ing-Simmons2000-11-191-0/+1
| | | | | | | Fix a couple of gross issues - double-include of ../deb.o in re.dll - win32sck.c needs PerlIO and FILE p4raw-id: //depot/perlio@7752
* Redo #7679 with LFs instead of CRLFs.Jarkko Hietaniemi2000-11-141-37/+37
| | | p4raw-id: //depot/perl@7680
* Get PerlIO building on Win32Benjamin Stuhl2000-11-141-2/+37
| | | | | Message-ID: <20001113230808.18659.qmail@web6305.mail.yahoo.com> p4raw-id: //depot/perl@7679
* tweak for change#7173Gurusamy Sarathy2000-10-091-0/+2
| | | | | p4raw-link: @7173 on //depot/perl: a10b7b7eee64efea010bfdba91243503341ba68d p4raw-id: //depot/perl@7181
* on Windows, avoid potential exception (could happen if MSVCRT isn'tGurusamy Sarathy2000-10-091-0/+1
| | | | | being used) when closing a socket handle p4raw-id: //depot/perl@7173
* change#6328 could make close(SOCKET) return false on windowsGurusamy Sarathy2000-08-161-8/+17
| | | | | | | when it shouldn't p4raw-link: @6328 on //depot/perl: 4e94524934c1af4124b2888d9716e5304ee50ad9 p4raw-id: //depot/perl@6657
* windows build tweaks (op/sprintf.t still fails tests 120-121, 149)Gurusamy Sarathy2000-07-111-1/+1
| | | p4raw-id: //depot/perl@6375
* accept() leaks memory on windows due to incorrect ordering ofGurusamy Sarathy2000-07-101-4/+5
| | | | | closesocket() and fclose() calls p4raw-id: //depot/perl@6328
* winsock options weren't being set in all threads under ithreadsGurusamy Sarathy2000-07-101-4/+4
| | | | | (caused send()s from second and subsequent threads to fail) p4raw-id: //depot/perl@6327
* winsock cleanup never done on Windows (leads to handle leaks)Gurusamy Sarathy2000-07-051-6/+7
| | | p4raw-id: //depot/perl@6317
* win32 internal data must be interpreter-localGurusamy Sarathy1999-11-081-22/+10
| | | p4raw-id: //depot/perl@4536
* yet more cleanups of the PERL_OBJECT, MULTIPLICITY and USE_THREADSGurusamy Sarathy1999-07-121-17/+17
| | | | | | | | | | | | | | | | builds; passing the implicit context is unified among the three flavors; PERL_IMPLICIT_CONTEXT is auto-enabled under all three flavors (see the top of perl.h) for testing; all varargs functions foo() have a va_list-taking variant vfoo() for generating the context-free versions; the PERL_OBJECT build should now be hyper-compatible with CPAN extensions (C++ is totally out of the picture) result has only been tested on Windows TODO: write docs on the THX rationale and idiomatic usage of the Perl API p4raw-id: //depot/perl@3667
* somewhat untested PERL_OBJECT cleanups (C++isms mostlyGurusamy Sarathy1999-06-271-1/+15
| | | | | | | | | gone from the public API); PERL_OBJECT builds again on windows TODO: namespace-clean the typedefs in iperlsys.h and elsewhere; remove C++ remnants from public headers p4raw-id: //depot/perl@3553
* win32 build fixesGurusamy Sarathy1999-06-101-20/+20
| | | p4raw-id: //depot/perl@3525
* win32_recvfrom() compatibility fixGurusamy Sarathy1998-11-211-0/+7
| | | p4raw-id: //depot/perl@2254
* fixes to enable PERL_OBJECT build with mingw32/egcs-1.0.2Gurusamy Sarathy1998-07-211-4/+0
| | | p4raw-id: //depot/perl@1612
* make 4-arg win32_select() sleep more reasonably on false valuesBlair Zajac1998-07-041-2/+5
| | | | | | | | | | | Message-Id: <199807020225.TAA18740@gobi.gps.caltech.edu> Date: Wed, 1 Jul 1998 19:25:56 -0700 (PDT) Subject: [PATCH 5.004_69] select dumps core on MSWin32-x86 -- Message-Id: <199807030107.SAA08595@gobi.gps.caltech.edu> Date: Thu, 2 Jul 1998 18:07:19 -0700 (PDT) Subject: [PATCH 5.004_69] select dumps core on MSWin32-x86 p4raw-id: //depot/perl@1303
* [asperl] add AS patch#21 (misc. fixes)Gurusamy Sarathy1998-05-271-1/+2
| | | p4raw-id: //depot/asperl@1036
* [asperl] integrate mainline changesGurusamy Sarathy1998-04-081-2/+27
|\ | | | | p4raw-id: //depot/asperl@884
| * [win32] set sockets to nonoverlapped mode for every threadSteve Nielsen1998-03-121-2/+27
| | | | | | | | | | | | Message-Id: <35081FE4.965A484D@enteract.com> Subject: [PATCH 5.004_62] win32: set sockopt on a per-thread basis p4raw-id: //depot/win32/perl@808