Re: Windows compilation - resource sections - Update

2011-07-22 Thread Mark Dootson
That's cleaner ! For info on the thread, Steve's pointer to Perl_win32_init(): see win32/win32.c. gives a much better way of determining if you have a compiler that automates manifests etc as well as having many different CRT features. i.e. #if _MSC_VER >= 1400 && defined(_WRITE_ABORT_MSG)

Re: Windows compilation - resource sections - Update

2011-07-22 Thread Roderich Schupp
On Fri, Jul 22, 2011 at 9:48 AM, Mark Dootson wrote: > So, the int / file descriptor we pass to close() is being interpreted as > invalid. Got it: the code for the first file written from boot.c does a second close() on an already closed file descriptor: i = my_mkfile( argv[0],

RE: Windows compilation - resource sections - Update

2011-07-22 Thread Steve Hay
Mark Dootson wrote on 2011-07-22: > Hi, > > In CRT versions greater than Server 2003, the close() function checks > its parameters. It expects a valid file descriptor ( the param check > definition seems to say that an int is expected which should be a valid > file descriptor.) > > So, the int /

Re: Windows compilation - resource sections - Update

2011-07-22 Thread Mark Dootson
Hi, In CRT versions greater than Server 2003, the close() function checks its parameters. It expects a valid file descriptor ( the param check definition seems to say that an int is expected which should be a valid file descriptor.) So, the int / file descriptor we pass to close() is being in

Re: Windows compilation - resource sections - Update

2011-07-21 Thread Roderich Schupp
On Thu, Jul 21, 2011 at 9:04 PM, Mark Dootson wrote: > The close(fh) statements in boot.c may cause application to crash if the CRT > version is 1400 or above for 32 bit or 1500 and above for 64 bit. What exactly is the problem with close(fh) here? Invalid fh? Cheers, Roderich

Re: Windows compilation - resource sections - Update

2011-07-21 Thread Mark Dootson
Hi, Just an update to this. I have now tested MS VC 2010 and have a couple of points. The close(fh) statements in boot.c may cause application to crash if the CRT version is 1400 or above for 32 bit or 1500 and above for 64 bit. So that would be MS VC 2005 and above. On older CRTs, close(fh