#include "config.h"
-#include <sys/stat.h>
-#include <sys/mman.h>
-#include <fcntl.h>
#include <errno.h>
#include <zlib.h>
#include "mm/memory.hpp"
#include "native/jni.hpp"
-#include "native/llni.h"
#include "native/native.hpp"
#if defined(ENABLE_JNI_HEADERS)
#include "threads/mutex.hpp"
-#include "vm/jit/builtin.hpp"
+#include "vm/array.hpp"
#include "vm/exceptions.hpp"
#include "vm/javaobjects.hpp"
+#include "vm/os.hpp"
#include "vm/string.hpp"
#include "vm/types.h"
#include "vm/vm.hpp" /* REMOVE ME: temporarily */
{
/* get pointer to the buffer */
// XXX Not GC safe.
- void* buf = &(LLNI_array_direct((java_handle_bytearray_t*) byteArray, off));
-
+ ByteArray ba(byteArray);
+ void* buf = (void*) (((int8_t*) ba.get_raw_data_ptr()) + off);
+
com_sun_cldchi_jvm_FileDescriptor fd(jobj);
int64_t filep = fd.get_pointer();