This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
disable unused Windows code that won't run on Windows 95
[perl5.git] / win32 / vmem.h
index cf3f502..0fcae27 100644 (file)
@@ -421,11 +421,19 @@ void VMem::FreeLock(void)
 
 int VMem::IsLocked(void)
 {
+#if 0
+    /* XXX TryEnterCriticalSection() is not available in some versions
+     * of Windows 95.  Since this code is not used anywhere yet, we 
+     * skirt the issue for now. */
     BOOL bAccessed = TryEnterCriticalSection(&m_cs);
     if(bAccessed) {
        LeaveCriticalSection(&m_cs);
     }
     return !bAccessed;
+#else
+    ASSERT(0); /* alarm bells for when somebody calls this */
+    return 0;
+#endif
 }