equal
deleted
inserted
replaced
31 |
31 |
32 class UnixNativeDispatcher { |
32 class UnixNativeDispatcher { |
33 protected UnixNativeDispatcher() { } |
33 protected UnixNativeDispatcher() { } |
34 |
34 |
35 // returns a NativeBuffer containing the given path |
35 // returns a NativeBuffer containing the given path |
36 private static NativeBuffer copyToNativeBuffer(UnixPath path) { |
36 static NativeBuffer copyToNativeBuffer(UnixPath path) { |
37 byte[] cstr = path.getByteArrayForSysCalls(); |
37 byte[] cstr = path.getByteArrayForSysCalls(); |
38 int size = cstr.length + 1; |
38 int size = cstr.length + 1; |
39 NativeBuffer buffer = NativeBuffers.getNativeBufferFromCache(size); |
39 NativeBuffer buffer = NativeBuffers.getNativeBufferFromCache(size); |
40 if (buffer == null) { |
40 if (buffer == null) { |
41 buffer = NativeBuffers.allocNativeBuffer(size); |
41 buffer = NativeBuffers.allocNativeBuffer(size); |