hotspot/src/os/windows/vm/perfMemory_windows.cpp
changeset 35212 7a6d0993a080
parent 27880 afb974a04396
child 36204 1c9f2970da66
--- a/hotspot/src/os/windows/vm/perfMemory_windows.cpp	Tue Dec 22 00:08:38 2015 +0000
+++ b/hotspot/src/os/windows/vm/perfMemory_windows.cpp	Tue Dec 22 05:26:55 2015 -0800
@@ -1308,25 +1308,21 @@
   // the file. This is important as the apis do not allow a terminating
   // JVM being monitored by another process to remove the file name.
   //
-  // the FILE_SHARE_DELETE share mode is valid only in winnt
-  //
   fh = CreateFile(
-             filename,                   /* LPCTSTR file name */
-
-             GENERIC_READ|GENERIC_WRITE, /* DWORD desired access */
+             filename,                          /* LPCTSTR file name */
 
-             (os::win32::is_nt() ? FILE_SHARE_DELETE : 0)|
-             FILE_SHARE_READ,            /* DWORD share mode, future READONLY
-                                          * open operations allowed
-                                          */
-             lpFileSA,                   /* LPSECURITY security attributes */
-             CREATE_ALWAYS,              /* DWORD creation disposition
-                                          * create file, if it already
-                                          * exists, overwrite it.
-                                          */
-             FILE_FLAG_DELETE_ON_CLOSE,  /* DWORD flags and attributes */
+             GENERIC_READ|GENERIC_WRITE,        /* DWORD desired access */
+             FILE_SHARE_DELETE|FILE_SHARE_READ, /* DWORD share mode, future READONLY
+                                                 * open operations allowed
+                                                 */
+             lpFileSA,                          /* LPSECURITY security attributes */
+             CREATE_ALWAYS,                     /* DWORD creation disposition
+                                                 * create file, if it already
+                                                 * exists, overwrite it.
+                                                 */
+             FILE_FLAG_DELETE_ON_CLOSE,         /* DWORD flags and attributes */
 
-             NULL);                      /* HANDLE template file access */
+             NULL);                             /* HANDLE template file access */
 
   free_security_attr(lpFileSA);
 
@@ -1734,7 +1730,7 @@
 //
 void PerfMemory::create_memory_region(size_t size) {
 
-  if (PerfDisableSharedMem || !os::win32::is_nt()) {
+  if (PerfDisableSharedMem) {
     // do not share the memory for the performance data.
     PerfDisableSharedMem = true;
     _start = create_standard_memory(size);