if (committed && reserved && committed < reserved)
{
/* Commit last of previous chunk cannot span allocations */
- addr = VirtualAlloc(committed,reserved-committed,MEM_COMMIT,PAGE_READWRITE);
+ addr = (char *) VirtualAlloc(committed,reserved-committed,MEM_COMMIT,PAGE_READWRITE);
if (addr)
committed = reserved;
}
* so lets system choose where we start, subsequent calls pass
* the old end address so ask for a contiguous block
*/
- addr = VirtualAlloc(reserved,size,MEM_RESERVE,PAGE_NOACCESS);
+ addr = (char *) VirtualAlloc(reserved,size,MEM_RESERVE,PAGE_NOACCESS);
if (addr)
{
reserved = addr+size;
if (brk > committed)
{
DWORD size = ((brk-committed + pagesize -1)/pagesize) * pagesize;
- char *addr = VirtualAlloc(committed,size,MEM_COMMIT,PAGE_READWRITE);
+ char *addr = (char *) VirtualAlloc(committed,size,MEM_COMMIT,PAGE_READWRITE);
if (addr)
{
committed += size;
#endif
}
+#ifdef USE_BINMODE_SCRIPTS
+
+void
+win32_strip_return(SV *sv)
+{
+ char *s = SvPVX(sv);
+ char *e = s+SvCUR(sv);
+ char *d = s;
+ while (s < e)
+ {
+ if (*s == '\r' && s[1] == '\n')
+ {
+ *d++ = '\n';
+ s += 2;
+ }
+ else
+ {
+ *d++ = *s++;
+ }
+ }
+ SvCUR_set(sv,d-SvPVX(sv));
+}
+
+#endif
+
+
+