diff options
author | Marc-Andre Laperle | 2014-09-04 18:12:11 +0000 |
---|---|---|
committer | Marc-Andre Laperle | 2014-09-10 04:55:09 +0000 |
commit | 1365760c92c23d84ecc347cbdfe47387f56b7948 (patch) | |
tree | 9f0e13bee274101d815e9786070e9c7fb100a5d2 | |
parent | 7914ce0ab5beddc276d3a540119c69ec4d1461c7 (diff) | |
download | org.eclipse.linuxtools-1365760c92c23d84ecc347cbdfe47387f56b7948.tar.gz org.eclipse.linuxtools-1365760c92c23d84ecc347cbdfe47387f56b7948.tar.xz org.eclipse.linuxtools-1365760c92c23d84ecc347cbdfe47387f56b7948.zip |
ctf: Fix NPE when running CTF Platform-less
Bug: 443643
Change-Id: I1281750ccfd32015974eec0ef4ef29f984921a29
Signed-off-by: Marc-Andre Laperle <marc-andre.laperle@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/32873
Reviewed-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Tested-by: Matthew Khouzam <matthew.khouzam@ericsson.com>
Tested-by: Hudson CI
Reviewed-on: https://git.eclipse.org/r/33148
-rw-r--r-- | lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/SafeMappedByteBuffer.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/SafeMappedByteBuffer.java b/lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/SafeMappedByteBuffer.java index 8b06b2733b..ff2f3459fe 100644 --- a/lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/SafeMappedByteBuffer.java +++ b/lttng/org.eclipse.linuxtools.ctf.core/src/org/eclipse/linuxtools/internal/ctf/core/SafeMappedByteBuffer.java @@ -16,8 +16,6 @@ import java.io.IOException; import java.nio.ByteBuffer; import java.nio.channels.FileChannel; -import org.eclipse.core.runtime.Platform; - /** * A common utility for mapping a ByteBuffer safely to work around a bug on * Windows which prevents deleting a file after it was mapped. On Windows, the @@ -28,7 +26,7 @@ import org.eclipse.core.runtime.Platform; */ public class SafeMappedByteBuffer { - private static final boolean IS_WIN32 = Platform.OS_WIN32.equals(Platform.getOS()); + private static final boolean IS_WIN32 = System.getProperty("os.name").startsWith("Windows"); //$NON-NLS-1$//$NON-NLS-2$ /** * Maps a region of this channel's file directly into memory. On Windows, |