/libcore/luni/src/main/native/ |
D | android_system_OsConstants.cpp | 61 static void initConstant(JNIEnv* env, jclass c, const char* fieldName, int value) { in initConstant() argument 62 jfieldID field = env->GetStaticFieldID(c, fieldName, "I"); in initConstant() 63 env->SetStaticIntField(c, field, value); in initConstant() 66 static void OsConstants_initConstants(JNIEnv* env, jclass c) { in OsConstants_initConstants() argument 67 initConstant(env, c, "AF_INET", AF_INET); in OsConstants_initConstants() 68 initConstant(env, c, "AF_INET6", AF_INET6); in OsConstants_initConstants() 69 initConstant(env, c, "AF_PACKET", AF_PACKET); in OsConstants_initConstants() 70 initConstant(env, c, "AF_NETLINK", AF_NETLINK); in OsConstants_initConstants() 71 initConstant(env, c, "AF_UNIX", AF_UNIX); in OsConstants_initConstants() 72 initConstant(env, c, "AF_VSOCK", AF_VSOCK); in OsConstants_initConstants() [all …]
|
D | java_lang_invoke_VarHandle.cpp | 20 static void ThrowUnsupportedOperationForAccessMode(JNIEnv* env, const char* accessMode) { in ThrowUnsupportedOperationForAccessMode() argument 25 jniThrowExceptionFmt(env, in ThrowUnsupportedOperationForAccessMode() 31 static jobject VarHandle_compareAndExchange(JNIEnv* env, jobject, jobjectArray) { in VarHandle_compareAndExchange() argument 33 ThrowUnsupportedOperationForAccessMode(env, "compareAndExchange"); in VarHandle_compareAndExchange() 37 static jobject VarHandle_compareAndExchangeAcquire(JNIEnv* env, jobject, jobjectArray) { in VarHandle_compareAndExchangeAcquire() argument 39 ThrowUnsupportedOperationForAccessMode(env, "compareAndExchangeAcquire"); in VarHandle_compareAndExchangeAcquire() 43 static jobject VarHandle_compareAndExchangeRelease(JNIEnv* env, jobject, jobjectArray) { in VarHandle_compareAndExchangeRelease() argument 45 ThrowUnsupportedOperationForAccessMode(env, "compareAndExchangeRelease"); in VarHandle_compareAndExchangeRelease() 49 static jboolean VarHandle_compareAndSet(JNIEnv* env, jobject, jobjectArray) { in VarHandle_compareAndSet() argument 51 ThrowUnsupportedOperationForAccessMode(env, "compareAndSet"); in VarHandle_compareAndSet() [all …]
|
D | JniConstants.h | 27 static void Initialize(JNIEnv* env); 32 static jclass GetBooleanClass(JNIEnv* env); 33 static jclass GetByteBufferClass(JNIEnv* env); 34 static jclass GetDoubleClass(JNIEnv* env); 35 static jclass GetErrnoExceptionClass(JNIEnv* env); 36 static jclass GetFileDescriptorClass(JNIEnv* env); 37 static jclass GetGaiExceptionClass(JNIEnv* env); 38 static jclass GetInet6AddressClass(JNIEnv* env); 39 static jclass GetInet6AddressHolderClass(JNIEnv* env); 40 static jclass GetInetAddressClass(JNIEnv* env); [all …]
|
D | libcore_io_Linux.cpp | 86 jstring NAME = env->NewStringUTF(EXP); \ 238 static void throwException(JNIEnv* env, jclass exceptionClass, jmethodID ctor3, jmethodID ctor2, in throwException() argument 241 if (env->ExceptionCheck()) { in throwException() 242 cause = env->ExceptionOccurred(); in throwException() 243 env->ExceptionClear(); in throwException() 246 ScopedLocalRef<jstring> detailMessage(env, env->NewStringUTF(functionName)); in throwException() 250 env->ExceptionClear(); in throwException() 255 exception = env->NewObject(exceptionClass, ctor3, detailMessage.get(), error, cause); in throwException() 257 exception = env->NewObject(exceptionClass, ctor2, detailMessage.get(), error); in throwException() 259 env->Throw(reinterpret_cast<jthrowable>(exception)); in throwException() [all …]
|
D | NetworkUtilities.cpp | 38 jobject sockaddrToInetAddress(JNIEnv* env, const sockaddr_storage& ss, jint* port) { in sockaddrToInetAddress() argument 53 return sockaddrToInetAddress(env, tmp, port); in sockaddrToInetAddress() 74 jniThrowExceptionFmt(env, "java/lang/IllegalArgumentException", in sockaddrToInetAddress() 82 ScopedLocalRef<jbyteArray> byteArray(env, env->NewByteArray(addressLength)); in sockaddrToInetAddress() 85 DCHECK(env->ExceptionCheck()); in sockaddrToInetAddress() 89 env->SetByteArrayRegion(byteArray.get(), 0, addressLength, in sockaddrToInetAddress() 92 jclass inetAddressClass = JniConstants::GetInetAddressClass(env); in sockaddrToInetAddress() 94 env->GetStaticMethodID(inetAddressClass, in sockaddrToInetAddress() 97 return env->CallStaticObjectMethod(inetAddressClass, in sockaddrToInetAddress() 104 static bool inetAddressToSockaddr(JNIEnv* env, jobject inetAddress, int port, sockaddr_storage& ss,… in inetAddressToSockaddr() argument [all …]
|
D | org_apache_harmony_xml_ExpatParser.cpp | 75 void push(JNIEnv* env, jstring s) { in push() argument 80 jniThrowOutOfMemoryError(env, NULL); in push() 110 : env(NULL), object(object), buffer(NULL), bufferSize(-1) { in ParsingContext() 127 env->DeleteGlobalRef(current->interned); in ~ParsingContext() 145 jcharArray javaBuffer = env->NewCharArray(length); in ensureCapacity() 149 javaBuffer = reinterpret_cast<jcharArray>(env->NewGlobalRef(javaBuffer)); in ensureCapacity() 161 env->DeleteGlobalRef(buffer); in freeBuffer() 172 JNIEnv* env; member 260 static InternedString* newInternedString(JNIEnv* env, const char* bytes, int hash) { in newInternedString() argument 264 jniThrowOutOfMemoryError(env, NULL); in newInternedString() [all …]
|
D | valueOf.cpp | 26 static jobject valueOf(JNIEnv* env, jclass c, const char* signature, const T& value) { in valueOf() argument 27 static jmethodID valueOfMethod = env->GetStaticMethodID(c, "valueOf", signature); in valueOf() 28 if (env->ExceptionCheck()) { in valueOf() 31 jobject result = env->CallStaticObjectMethod(c, valueOfMethod, value); in valueOf() 32 if (env->ExceptionCheck()) { in valueOf() 38 jobject booleanValueOf(JNIEnv* env, jboolean value) { in booleanValueOf() argument 39 return valueOf(env, JniConstants::GetBooleanClass(env), "(Z)Ljava/lang/Boolean;", value); in booleanValueOf() 42 jobject doubleValueOf(JNIEnv* env, jdouble value) { in doubleValueOf() argument 43 return valueOf(env, JniConstants::GetDoubleClass(env), "(D)Ljava/lang/Double;", value); in doubleValueOf() 46 jobject integerValueOf(JNIEnv* env, jint value) { in integerValueOf() argument [all …]
|
/libcore/ojluni/src/main/native/ |
D | jni_util.c | 45 JNU_ThrowByName(JNIEnv *env, const char *name, const char *msg) in JNU_ThrowByName() argument 47 jclass cls = (*env)->FindClass(env, name); in JNU_ThrowByName() 50 (*env)->ThrowNew(env, cls, msg); in JNU_ThrowByName() 56 JNU_ThrowNullPointerException(JNIEnv *env, const char *msg) in JNU_ThrowNullPointerException() argument 58 JNU_ThrowByName(env, "java/lang/NullPointerException", msg); in JNU_ThrowNullPointerException() 62 JNU_ThrowArrayIndexOutOfBoundsException(JNIEnv *env, const char *msg) in JNU_ThrowArrayIndexOutOfBoundsException() argument 64 JNU_ThrowByName(env, "java/lang/ArrayIndexOutOfBoundsException", msg); in JNU_ThrowArrayIndexOutOfBoundsException() 68 JNU_ThrowOutOfMemoryError(JNIEnv *env, const char *msg) in JNU_ThrowOutOfMemoryError() argument 70 JNU_ThrowByName(env, "java/lang/OutOfMemoryError", msg); in JNU_ThrowOutOfMemoryError() 74 JNU_ThrowIllegalArgumentException(JNIEnv *env, const char *msg) in JNU_ThrowIllegalArgumentException() argument [all …]
|
D | OnLoad.cpp | 25 extern "C" void register_java_util_zip_ZipFile(JNIEnv* env); 26 extern "C" void register_java_util_zip_Inflater(JNIEnv* env); 27 extern "C" void register_java_util_zip_Deflater(JNIEnv* env); 28 extern "C" void register_java_io_FileDescriptor(JNIEnv* env); 29 extern "C" void register_sun_nio_ch_DatagramChannelImpl(JNIEnv* env); 30 extern "C" void register_sun_nio_ch_DatagramDispatcher(JNIEnv* env); 31 extern "C" void register_java_io_Console(JNIEnv* env); 32 extern "C" void register_sun_nio_ch_IOUtil(JNIEnv* env); 33 extern "C" void register_sun_nio_ch_SocketChannelImpl(JNIEnv* env); 34 extern "C" void register_sun_nio_ch_FileChannelImpl(JNIEnv* env); [all …]
|
D | System.c | 49 jstring jkey = (*env)->NewStringUTF(env, key); \ 50 jstring jval = (*env)->NewStringUTF(env, val); \ 51 jobject r = (*env)->CallObjectMethod(env, props, putID, jkey, jval); \ 52 if ((*env)->ExceptionOccurred(env)) return NULL; \ 53 (*env)->DeleteLocalRef(env, jkey); \ 54 (*env)->DeleteLocalRef(env, jval); \ 55 (*env)->DeleteLocalRef(env, r); \ 63 jstring jkey = (*env)->NewStringUTF(env, key); \ 64 jstring jval = GetStringPlatform(env, val); \ 65 jobject r = (*env)->CallObjectMethod(env, props, putID, jkey, jval); \ [all …]
|
D | net_util.c | 43 JNIEnv *env; in net_JNI_OnLoad() local 45 if ((*vm)->GetEnv(vm, (void **)&env, JNI_VERSION_1_2) == JNI_OK) { in net_JNI_OnLoad() 47 JNU_ThrowByName(env, "java/lang/UnsatisfiedLinkError", in net_JNI_OnLoad() 60 parseExclusiveBindProperty(env); in net_JNI_OnLoad() 80 jobject getInet6Address_scopeifname(JNIEnv *env, jobject iaObj) { in getInet6Address_scopeifname() argument 84 holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID); in getInet6Address_scopeifname() 86 return (*env)->GetObjectField(env, holder, ia6_scopeifnameID); in getInet6Address_scopeifname() 89 int setInet6Address_scopeifname(JNIEnv *env, jobject iaObj, jobject scopeifname) { in setInet6Address_scopeifname() argument 93 holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID); in setInet6Address_scopeifname() 95 (*env)->SetObjectField(env, holder, ia6_scopeifnameID, scopeifname); in setInet6Address_scopeifname() [all …]
|
D | Deflater.c | 51 static void Deflater_initIDs(JNIEnv *env) { in Deflater_initIDs() argument 52 jclass cls = (*env)->FindClass(env, "java/util/zip/Deflater"); in Deflater_initIDs() 53 levelID = (*env)->GetFieldID(env, cls, "level", "I"); in Deflater_initIDs() 54 strategyID = (*env)->GetFieldID(env, cls, "strategy", "I"); in Deflater_initIDs() 55 setParamsID = (*env)->GetFieldID(env, cls, "setParams", "Z"); in Deflater_initIDs() 56 finishID = (*env)->GetFieldID(env, cls, "finish", "Z"); in Deflater_initIDs() 57 finishedID = (*env)->GetFieldID(env, cls, "finished", "Z"); in Deflater_initIDs() 58 bufID = (*env)->GetFieldID(env, cls, "buf", "[B"); in Deflater_initIDs() 59 offID = (*env)->GetFieldID(env, cls, "off", "I"); in Deflater_initIDs() 60 lenID = (*env)->GetFieldID(env, cls, "len", "I"); in Deflater_initIDs() [all …]
|
D | Inflater.c | 44 #define ThrowDataFormatException(env, msg) \ argument 45 JNU_ThrowByName(env, "java/util/zip/DataFormatException", msg) 51 static void Inflater_initIDs(JNIEnv *env) { in Inflater_initIDs() argument 52 jclass cls = (*env)->FindClass(env, "java/util/zip/Inflater"); in Inflater_initIDs() 53 needDictID = (*env)->GetFieldID(env, cls, "needDict", "Z"); in Inflater_initIDs() 54 finishedID = (*env)->GetFieldID(env, cls, "finished", "Z"); in Inflater_initIDs() 55 bufID = (*env)->GetFieldID(env, cls, "buf", "[B"); in Inflater_initIDs() 56 offID = (*env)->GetFieldID(env, cls, "off", "I"); in Inflater_initIDs() 57 lenID = (*env)->GetFieldID(env, cls, "len", "I"); in Inflater_initIDs() 61 Inflater_init(JNIEnv *env, jclass cls, jboolean nowrap) in Inflater_init() argument [all …]
|
D | ObjectStreamClass.c | 36 static void ObjectStreamClass_initNative(JNIEnv *env) in ObjectStreamClass_initNative() argument 38 jclass cl = (*env)->FindClass(env, "java/lang/NoSuchMethodError"); in ObjectStreamClass_initNative() 42 noSuchMethodErrCl = (*env)->NewGlobalRef(env, cl); in ObjectStreamClass_initNative() 57 ObjectStreamClass_hasStaticInitializer(JNIEnv *env, jclass this, in ObjectStreamClass_hasStaticInitializer() argument 68 (*env)->GetStaticMethodID(env, clazz, "<clinit>", "()V"); in ObjectStreamClass_hasStaticInitializer() 70 jthrowable th = (*env)->ExceptionOccurred(env); in ObjectStreamClass_hasStaticInitializer() 71 (*env)->ExceptionClear(env); /* normal return */ in ObjectStreamClass_hasStaticInitializer() 72 if (!(*env)->IsInstanceOf(env, th, noSuchMethodErrCl)) { in ObjectStreamClass_hasStaticInitializer() 73 (*env)->Throw(env, th); in ObjectStreamClass_hasStaticInitializer() 96 if ((superCl = (*env)->GetSuperclass(env, clazz)) == NULL) { in ObjectStreamClass_hasStaticInitializer() [all …]
|
D | jni_util.h | 49 JNU_ThrowByName(JNIEnv *env, const char *name, const char *msg); 53 JNU_ThrowNullPointerException(JNIEnv *env, const char *msg); 56 JNU_ThrowArrayIndexOutOfBoundsException(JNIEnv *env, const char *msg); 59 JNU_ThrowOutOfMemoryError(JNIEnv *env, const char *msg); 62 JNU_ThrowIllegalArgumentException(JNIEnv *env, const char *msg); 65 JNU_ThrowIllegalAccessError(JNIEnv *env, const char *msg); 68 JNU_ThrowIllegalAccessException(JNIEnv *env, const char *msg); 71 JNU_ThrowInternalError(JNIEnv *env, const char *msg); 74 JNU_ThrowIOException(JNIEnv *env, const char *msg); 77 JNU_ThrowNoSuchFieldException(JNIEnv *env, const char *msg); [all …]
|
D | UnixNativeDispatcher.c | 169 static void throwUnixException(JNIEnv* env, int errnum) { in throwUnixException() argument 170 jobject x = JNU_NewObjectByName(env, "sun/nio/fs/UnixException", in throwUnixException() 173 (*env)->Throw(env, x); in throwUnixException() 181 Java_sun_nio_fs_UnixNativeDispatcher_init(JNIEnv* env, jclass this) in Java_sun_nio_fs_UnixNativeDispatcher_init() argument 186 clazz = (*env)->FindClass(env, "sun/nio/fs/UnixFileAttributes"); in Java_sun_nio_fs_UnixNativeDispatcher_init() 188 attrs_st_mode = (*env)->GetFieldID(env, clazz, "st_mode", "I"); in Java_sun_nio_fs_UnixNativeDispatcher_init() 190 attrs_st_ino = (*env)->GetFieldID(env, clazz, "st_ino", "J"); in Java_sun_nio_fs_UnixNativeDispatcher_init() 192 attrs_st_dev = (*env)->GetFieldID(env, clazz, "st_dev", "J"); in Java_sun_nio_fs_UnixNativeDispatcher_init() 194 attrs_st_rdev = (*env)->GetFieldID(env, clazz, "st_rdev", "J"); in Java_sun_nio_fs_UnixNativeDispatcher_init() 196 attrs_st_nlink = (*env)->GetFieldID(env, clazz, "st_nlink", "I"); in Java_sun_nio_fs_UnixNativeDispatcher_init() [all …]
|
D | ZipFile.c | 62 static void ZipFile_initIDs(JNIEnv *env) in ZipFile_initIDs() argument 64 jclass cls = (*env)->FindClass(env, "java/util/zip/ZipFile"); in ZipFile_initIDs() 65 jzfileID = (*env)->GetFieldID(env, cls, "jzfile", "J"); in ZipFile_initIDs() 67 jzOnZipEntryAccessID = (*env)->GetMethodID(env, cls, "onZipEntryAccess", "([BI)V"); in ZipFile_initIDs() 73 ThrowZipException(JNIEnv *env, const char *msg) in ThrowZipException() argument 79 s = JNU_NewStringPlatform(env, msg); in ThrowZipException() 81 x = JNU_NewObjectByName(env, in ThrowZipException() 85 (*env)->Throw(env, x); in ThrowZipException() 91 ZipFile_open(JNIEnv *env, jobject thiz, jstring name, in ZipFile_open() argument 95 const char *path = JNU_GetStringPlatformChars(env, name, 0); in ZipFile_open() [all …]
|
D | UnixDomainSockets.c | 53 jbyteArray sockaddrToUnixAddressBytes(JNIEnv *env, struct sockaddr_un *sa, socklen_t len) in sockaddrToUnixAddressBytes() argument 62 jbyteArray name = (*env)->NewByteArray(env, namelen); in sockaddrToUnixAddressBytes() 64 (*env)->SetByteArrayRegion(env, name, 0, namelen, (jbyte*)sa->sun_path); in sockaddrToUnixAddressBytes() 65 if ((*env)->ExceptionOccurred(env)) { in sockaddrToUnixAddressBytes() 74 jint unixSocketAddressToSockaddr(JNIEnv *env, jbyteArray path, struct sockaddr_un *sa, int *len) in unixSocketAddressToSockaddr() argument 79 const char* pname = (const char *)(*env)->GetByteArrayElements(env, path, NULL); in unixSocketAddressToSockaddr() 81 JNU_ThrowByName(env, JNU_JAVANETPKG "SocketException", "Unix domain path not present"); in unixSocketAddressToSockaddr() 84 size_t name_len = (*env)->GetArrayLength(env, path); in unixSocketAddressToSockaddr() 86 JNU_ThrowByName(env, JNU_JAVANETPKG "SocketException", "Unix domain path too long"); in unixSocketAddressToSockaddr() 93 (*env)->ReleaseByteArrayElements(env, path, (jbyte *)pname, 0); in unixSocketAddressToSockaddr() [all …]
|
D | Inet6Address.c | 47 static void Inet6Address_init(JNIEnv *env) { in Inet6Address_init() argument 49 jclass c = (*env)->FindClass(env, "java/net/Inet6Address"); in Inet6Address_init() 51 ia6_class = (*env)->NewGlobalRef(env, c); in Inet6Address_init() 53 ia6h_class = (*env)->FindClass(env, "java/net/Inet6Address$Inet6AddressHolder"); in Inet6Address_init() 55 …ia6_holder6ID = (*env)->GetFieldID(env, ia6_class, "holder6", "Ljava/net/Inet6Address$Inet6Address… in Inet6Address_init() 57 ia6_ipaddressID = (*env)->GetFieldID(env, ia6h_class, "ipaddress", "[B"); in Inet6Address_init() 59 ia6_scopeidID = (*env)->GetFieldID(env, ia6h_class, "scope_id", "I"); in Inet6Address_init() 61 ia6_scopeidsetID = (*env)->GetFieldID(env, ia6h_class, "scope_id_set", "Z"); in Inet6Address_init() 63 …ia6_scopeifnameID = (*env)->GetFieldID(env, ia6h_class, "scope_ifname", "Ljava/net/NetworkInterfac… in Inet6Address_init() 65 ia6_ctrID = (*env)->GetMethodID(env, ia6_class, "<init>", "()V"); in Inet6Address_init() [all …]
|
D | InetAddress.c | 46 static void InetAddress_init(JNIEnv *env) { in InetAddress_init() argument 47 jclass c = (*env)->FindClass(env,"java/net/InetAddress"); in InetAddress_init() 49 ia_class = (*env)->NewGlobalRef(env, c); in InetAddress_init() 51 c = (*env)->FindClass(env,"java/net/InetAddress$InetAddressHolder"); in InetAddress_init() 53 iac_class = (*env)->NewGlobalRef(env, c); in InetAddress_init() 54 …ia_holderID = (*env)->GetFieldID(env, ia_class, "holder", "Ljava/net/InetAddress$InetAddressHolder… in InetAddress_init() 57 iac_addressID = (*env)->GetFieldID(env, iac_class, "address", "I"); in InetAddress_init() 59 iac_familyID = (*env)->GetFieldID(env, iac_class, "family", "I"); in InetAddress_init() 61 iac_hostNameID = (*env)->GetFieldID(env, iac_class, "hostName", "Ljava/lang/String;"); in InetAddress_init() 63 … iac_origHostNameID = (*env)->GetFieldID(env, iac_class, "originalHostName", "Ljava/lang/String;"); in InetAddress_init() [all …]
|
D | LinuxNativeDispatcher.c | 54 static void throwUnixException(JNIEnv* env, int errnum) { in throwUnixException() argument 55 jobject x = JNU_NewObjectByName(env, "sun/nio/fs/UnixException", in throwUnixException() 58 (*env)->Throw(env, x); in throwUnixException() 63 Java_sun_nio_fs_LinuxNativeDispatcher_init(JNIEnv *env, jclass clazz) in Java_sun_nio_fs_LinuxNativeDispatcher_init() argument 70 clazz = (*env)->FindClass(env, "sun/nio/fs/UnixMountEntry"); in Java_sun_nio_fs_LinuxNativeDispatcher_init() 72 entry_name = (*env)->GetFieldID(env, clazz, "name", "[B"); in Java_sun_nio_fs_LinuxNativeDispatcher_init() 74 entry_dir = (*env)->GetFieldID(env, clazz, "dir", "[B"); in Java_sun_nio_fs_LinuxNativeDispatcher_init() 76 entry_fstype = (*env)->GetFieldID(env, clazz, "fstype", "[B"); in Java_sun_nio_fs_LinuxNativeDispatcher_init() 78 entry_options = (*env)->GetFieldID(env, clazz, "opts", "[B"); in Java_sun_nio_fs_LinuxNativeDispatcher_init() 83 Java_sun_nio_fs_LinuxNativeDispatcher_fgetxattr0(JNIEnv* env, jclass clazz, in Java_sun_nio_fs_LinuxNativeDispatcher_fgetxattr0() argument [all …]
|
D | DatagramChannelImpl.c | 61 Java_sun_nio_ch_DatagramChannelImpl_initIDs(JNIEnv *env, jclass clazz) in Java_sun_nio_ch_DatagramChannelImpl_initIDs() argument 63 clazz = (*env)->FindClass(env, "java/net/InetSocketAddress"); in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 65 isa_class = (*env)->NewGlobalRef(env, clazz); in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 67 JNU_ThrowOutOfMemoryError(env, NULL); in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 70 isa_ctorID = (*env)->GetMethodID(env, clazz, "<init>", in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 74 clazz = (*env)->FindClass(env, "sun/nio/ch/DatagramChannelImpl"); in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 76 dci_senderID = (*env)->GetFieldID(env, clazz, "sender", in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 79 dci_senderAddrID = (*env)->GetFieldID(env, clazz, in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 83 dci_senderPortID = (*env)->GetFieldID(env, clazz, in Java_sun_nio_ch_DatagramChannelImpl_initIDs() 89 Java_sun_nio_ch_DatagramChannelImpl_disconnect0(JNIEnv *env, jobject this, in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() argument [all …]
|
D | io_util.c | 40 readSingle(JNIEnv *env, jobject this, jfieldID fid) { in readSingle() argument 45 JNU_ThrowIOException(env, "Stream Closed"); in readSingle() 52 JNU_ThrowIOExceptionWithLastError(env, "Read error"); in readSingle() 54 JNU_ThrowByName(env, "java/io/InterruptedIOException", NULL); in readSingle() 68 outOfBounds(JNIEnv *env, jint off, jint len, jbyteArray array) { in outOfBounds() argument 73 ((*env)->GetArrayLength(env, array) - off < len)); in outOfBounds() 77 readBytes(JNIEnv *env, jobject this, jbyteArray bytes, in readBytes() argument 86 JNU_ThrowNullPointerException(env, NULL); in readBytes() 90 if (outOfBounds(env, off, len, bytes)) { in readBytes() 91 JNU_ThrowByName(env, "java/lang/IndexOutOfBoundsException", NULL); in readBytes() [all …]
|
D | ServerSocketChannelImpl.c | 61 Java_sun_nio_ch_ServerSocketChannelImpl_initIDs(JNIEnv *env, jclass c) in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() argument 65 cls = (*env)->FindClass(env, "java/io/FileDescriptor"); in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 67 fd_fdID = (*env)->GetFieldID(env, cls, "descriptor", "I"); in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 70 cls = (*env)->FindClass(env, "java/net/InetSocketAddress"); in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 72 isa_class = (*env)->NewGlobalRef(env, cls); in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 74 JNU_ThrowOutOfMemoryError(env, NULL); in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 77 isa_ctorID = (*env)->GetMethodID(env, cls, "<init>", in Java_sun_nio_ch_ServerSocketChannelImpl_initIDs() 83 Java_sun_nio_ch_ServerSocketChannelImpl_accept0(JNIEnv *env, jobject this, in Java_sun_nio_ch_ServerSocketChannelImpl_accept0() argument 87 jint ssfd = (*env)->GetIntField(env, ssfdo, fd_fdID); in Java_sun_nio_ch_ServerSocketChannelImpl_accept0() 97 JNU_ThrowOutOfMemoryError(env, NULL); in Java_sun_nio_ch_ServerSocketChannelImpl_accept0() [all …]
|
D | ObjectInputStream.c | 48 Java_java_io_ObjectInputStream_bytesToFloats(JNIEnv *env, in Java_java_io_ObjectInputStream_bytesToFloats() argument 70 JNU_ThrowNullPointerException(env, NULL); in Java_java_io_ObjectInputStream_bytesToFloats() 73 bytes = (*env)->GetPrimitiveArrayCritical(env, src, NULL); in Java_java_io_ObjectInputStream_bytesToFloats() 79 (*env)->ReleasePrimitiveArrayCritical(env, src, bytes, JNI_ABORT); in Java_java_io_ObjectInputStream_bytesToFloats() 80 JNU_ThrowNullPointerException(env, NULL); in Java_java_io_ObjectInputStream_bytesToFloats() 83 floats = (*env)->GetPrimitiveArrayCritical(env, dst, NULL); in Java_java_io_ObjectInputStream_bytesToFloats() 85 (*env)->ReleasePrimitiveArrayCritical(env, src, bytes, JNI_ABORT); in Java_java_io_ObjectInputStream_bytesToFloats() 101 (*env)->ReleasePrimitiveArrayCritical(env, src, bytes, JNI_ABORT); in Java_java_io_ObjectInputStream_bytesToFloats() 102 (*env)->ReleasePrimitiveArrayCritical(env, dst, floats, 0); in Java_java_io_ObjectInputStream_bytesToFloats() 115 Java_java_io_ObjectInputStream_bytesToDoubles(JNIEnv *env, in Java_java_io_ObjectInputStream_bytesToDoubles() argument [all …]
|