summaryrefslogtreecommitdiff
path: root/win32/vmem.h
diff options
context:
space:
mode:
authorNick Ing-Simmons <nik@tiuk.ti.com>2002-01-14 22:02:49 +0000
committerNick Ing-Simmons <nik@tiuk.ti.com>2002-01-14 22:02:49 +0000
commit05ec9bb346c404c8906ed1ac374d4bce61c84f5d (patch)
treec0c3deb21e984b2371d1058155b645467055217d /win32/vmem.h
parente567eb179f8c37fa2e2a16e90180982901849683 (diff)
downloadperl-05ec9bb346c404c8906ed1ac374d4bce61c84f5d.tar.gz
Use PerlMemShared for CopSTASHPV and CopFILE. MUCH harder than it sounds!
Need to use CopXXXXX macros everywhere and add CopSTASH_free Add new scope type and add support for it to scope.c and scope stack dup-er in sv.c. Add savesharedpv(). Also zealous version of Win32's vmem.h to catch all the abuses. With this t/op/fork.t passes even with zealous checking and checker is point a finger at various threads/shared issues. PL_curcop->cop_io is still an issue. p4raw-id: //depot/perlio@14259
Diffstat (limited to 'win32/vmem.h')
-rw-r--r--win32/vmem.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/win32/vmem.h b/win32/vmem.h
index a60459dfe1..712a76edad 100644
--- a/win32/vmem.h
+++ b/win32/vmem.h
@@ -200,15 +200,17 @@ void VMem::Free(void* pMem)
if (pMem) {
PMEMORY_BLOCK_HEADER ptr = (PMEMORY_BLOCK_HEADER)(((char*)pMem)-sizeof(MEMORY_BLOCK_HEADER));
if (ptr->owner != this) {
-#if 0
- int *nowhere = NULL;
- *nowhere = 0;
-#else
if (ptr->owner) {
- ptr->owner->Free(pMem);
+#if 1
+ dTHX;
+ int *nowhere = NULL;
+ Perl_warn(aTHX_ "Free to wrong pool %p not %p",this,ptr->owner);
+ *nowhere = 0;
+#else
+ ptr->owner->Free(pMem);
+#endif
}
return;
-#endif
}
GetLock();
UnlinkBlock(ptr);