/libcore/ojluni/src/main/java/sun/nio/fs/ |
D | UnixException.java | 38 private int errno; field in UnixException 41 UnixException(int errno) { in UnixException() argument 42 this.errno = errno; in UnixException() 47 this.errno = 0; in UnixException() 51 int errno() { in errno() method in UnixException 52 return errno; in errno() 55 void setError(int errno) { in setError() argument 56 this.errno = errno; in setError() 64 return Util.toString(UnixNativeDispatcher.strerror(errno())); in errorString() 83 if (errno() == UnixConstants.EACCES) in translateToIOException() [all …]
|
D | UnixCopyFile.java | 390 if (x.errno() == EXDEV) { in move() 442 (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) in move() 456 if (x.errno() != EXDEV && x.errno() != EISDIR) { in move() 495 (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) in move() 561 (x.errno() == EEXIST || x.errno() == ENOTEMPTY)) in copy()
|
/libcore/luni/src/main/java/android/system/ |
D | OsConstants.java | 680 public static String errnoName(int errno) { in errnoName() argument 681 if (errno == E2BIG) { in errnoName() 684 if (errno == EACCES) { in errnoName() 687 if (errno == EADDRINUSE) { in errnoName() 690 if (errno == EADDRNOTAVAIL) { in errnoName() 693 if (errno == EAFNOSUPPORT) { in errnoName() 696 if (errno == EAGAIN) { in errnoName() 699 if (errno == EALREADY) { in errnoName() 702 if (errno == EBADF) { in errnoName() 705 if (errno == EBADMSG) { in errnoName() [all …]
|
D | ErrnoException.java | 34 public final int errno; field in ErrnoException 39 public ErrnoException(String functionName, int errno) { in ErrnoException() argument 41 this.errno = errno; in ErrnoException() 47 public ErrnoException(String functionName, int errno, Throwable cause) { in ErrnoException() argument 50 this.errno = errno; in ErrnoException() 59 String errnoName = OsConstants.errnoName(errno); in getMessage() 61 errnoName = "errno " + errno; in getMessage() 63 String description = Libcore.os.strerror(errno); in getMessage()
|
/libcore/ojluni/src/main/native/ |
D | FileChannelImpl.c | 71 if (errno == EINTR) in handle() 108 if (errno == ENOMEM) { in FileChannelImpl_map0() 171 if (errno == EAGAIN) in FileChannelImpl_transferTo0() 173 if ((errno == EINVAL) && ((ssize_t)count >= 0)) in FileChannelImpl_transferTo0() 175 if (errno == EINTR) { in FileChannelImpl_transferTo0() 200 if (errno == EAGAIN) in FileChannelImpl_transferTo0() 202 if (errno == EOPNOTSUPP) in FileChannelImpl_transferTo0() 204 if ((errno == EINVAL) && ((ssize_t)count >= 0)) in FileChannelImpl_transferTo0() 206 if (errno == EINTR) in FileChannelImpl_transferTo0() 224 if (errno == EAGAIN) in FileChannelImpl_transferTo0() [all …]
|
D | UnixNativeDispatcher.c | 76 } while((_result == -1) && (errno == EINTR)); \ 82 } while((_result == NULL) && (errno == EINTR)); \ 297 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_getcwd() 337 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_dup() 352 } while (fp == NULL && errno == EINTR); in Java_sun_nio_fs_UnixNativeDispatcher_fopen0() 355 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_fopen0() 371 if (fclose(fp) == EOF && errno != EINTR) { in Java_sun_nio_fs_UnixNativeDispatcher_fclose() 372 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_fclose() 385 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_open0() 404 throwUnixException(env, errno); in Java_sun_nio_fs_UnixNativeDispatcher_openat0() [all …]
|
D | canonicalize_md.c | 193 errno = EINVAL; in canonicalize() 198 errno = ENAMETOOLONG; in canonicalize() 216 errno = ENAMETOOLONG; in canonicalize() 237 else if (errno == ENOENT || errno == ENOTDIR || errno == EACCES || errno == ENOTCONN) { in canonicalize() 259 errno = ENAMETOOLONG; in canonicalize()
|
D | DatagramChannelImpl.c | 130 if (rv < 0 && errno == EADDRNOTAVAIL) in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() 131 rv = errno = 0; in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() 138 if (rv < 0 && errno == EAFNOSUPPORT) in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() 139 rv = errno = 0; in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() 145 handleSocketError(env, errno); in Java_sun_nio_ch_DatagramChannelImpl_disconnect0() 172 if (errno == EWOULDBLOCK) { in Java_sun_nio_ch_DatagramChannelImpl_receive0() 175 if (errno == EINTR) { in Java_sun_nio_ch_DatagramChannelImpl_receive0() 178 if (errno == ECONNREFUSED) { in Java_sun_nio_ch_DatagramChannelImpl_receive0() 187 return handleSocketError(env, errno); in Java_sun_nio_ch_DatagramChannelImpl_receive0() 262 if (errno == EAGAIN) { in Java_sun_nio_ch_DatagramChannelImpl_send0() [all …]
|
D | linux_close.cpp | 76 } while (rv == -1 && errno == EINTR); in closefd() 87 errno = EBADF; in NET_Dup2() 117 _syscallErrno = errno; \ 120 errno = _wasSignaled ? EBADF : _syscallErrno; \ 121 } while (ret == -1 && errno == EINTR); \ 196 errno = EBADF; in NET_Timeout() 224 syscallErrno = errno; in NET_Timeout() 227 errno = wasSignaled ? EBADF : syscallErrno; in NET_Timeout() 233 if (rv < 0 && errno == EINTR) { in NET_Timeout()
|
D | Net.c | 246 return handleSocketError(env, errno); in Java_sun_nio_ch_Net_socket0() 281 (errno != ENOPROTOOPT)) { in Java_sun_nio_ch_Net_socket0() 322 handleSocketError(env, errno); in Java_sun_nio_ch_Net_bind0() 330 handleSocketError(env, errno); in Java_sun_nio_ch_Net_listen() 349 if (errno == EINPROGRESS) { in Java_sun_nio_ch_Net_connect0() 351 } else if (errno == EINTR) { in Java_sun_nio_ch_Net_connect0() 354 return handleSocketErrorWithDefault(env, errno, JNU_JAVANETPKG "ConnectException"); in Java_sun_nio_ch_Net_connect0() 373 if (errno == ECONNRESET) { in Java_sun_nio_ch_Net_localPort() 382 handleSocketError(env, errno); in Java_sun_nio_ch_Net_localPort() 386 handleSocketError(env, errno); in Java_sun_nio_ch_Net_localPort() [all …]
|
D | LinuxNativeDispatcher.c | 91 errno = ENOTSUP; in Java_sun_nio_fs_LinuxNativeDispatcher_fgetxattr0() 97 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxNativeDispatcher_fgetxattr0() 110 errno = ENOTSUP; in Java_sun_nio_fs_LinuxNativeDispatcher_fsetxattr0() 116 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxNativeDispatcher_fsetxattr0() 127 errno = ENOTSUP; in Java_sun_nio_fs_LinuxNativeDispatcher_fremovexattr0() 133 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxNativeDispatcher_fremovexattr0() 144 errno = ENOTSUP; in Java_sun_nio_fs_LinuxNativeDispatcher_flistxattr() 150 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxNativeDispatcher_flistxattr() 164 } while (fp == NULL && errno == EINTR); in Java_sun_nio_fs_LinuxNativeDispatcher_setmntent0() 166 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxNativeDispatcher_setmntent0()
|
D | LinuxWatchService.c | 77 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxWatchService_inotifyInit() 91 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxWatchService_inotifyAddWatch() 102 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxWatchService_inotifyRmWatch() 123 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxWatchService_socketpair() 146 if (errno == EINTR) { in Java_sun_nio_fs_LinuxWatchService_poll() 149 throwUnixException(env, errno); in Java_sun_nio_fs_LinuxWatchService_poll()
|
D | FileSystemPreferences.c | 50 result = errno; in Java_java_util_prefs_FileSystemPreferences_chmod() 90 result[1] = errno; in Java_java_util_prefs_FileSystemPreferences_lockFile0() 102 result[1] = errno; in Java_java_util_prefs_FileSystemPreferences_lockFile0() 139 return (jint)errno; in Java_java_util_prefs_FileSystemPreferences_unlockFile0() 143 return (jint) errno; in Java_java_util_prefs_FileSystemPreferences_unlockFile0()
|
D | UnixCopyFile.c | 38 } while((_result == -1) && (errno == EINTR)); \ 64 throwUnixException(env, errno); in Java_sun_nio_fs_UnixCopyFile_transfer() 78 throwUnixException(env, errno); in Java_sun_nio_fs_UnixCopyFile_transfer()
|
D | IOUtil.c | 120 if ((n < 0) && (errno != EAGAIN)) in IOUtil_drain() 167 else if (errno == EAGAIN) in convertReturnVal() 169 else if (errno == EINTR) in convertReturnVal() 192 else if (errno == EAGAIN) in convertLongReturnVal() 194 else if (errno == EINTR) in convertLongReturnVal()
|
D | UNIXProcess_md.c | 162 } while(((_result) == -1) && (errno == EINTR)); \ 334 switch (errno) { in UNIXProcess_waitForProcessExit() 565 if (errno == ENOEXEC) in execve_with_shell_fallback() 592 errno = ENOENT; in JDK_execvpe() 608 errno = ENAMETOOLONG; in JDK_execvpe() 627 switch (errno) { in JDK_execvpe() 629 sticky_errno = errno; in JDK_execvpe() 651 errno = sticky_errno; in JDK_execvpe() 677 } else if (errno == EINTR) { in readFully() 755 if (restartableClose(fd) == -1 && errno != EBADF) in childProcess() [all …]
|
D | DatagramDispatcher.c | 57 if (result < 0 && errno == ECONNREFUSED) { in Java_sun_nio_ch_DatagramDispatcher_read0() 90 if (result < 0 && errno == ECONNREFUSED) { in Java_sun_nio_ch_DatagramDispatcher_readv0() 104 if (result < 0 && errno == ECONNREFUSED) { in Java_sun_nio_ch_DatagramDispatcher_write0() 135 if (result < 0 && errno == ECONNREFUSED) { in Java_sun_nio_ch_DatagramDispatcher_writev0()
|
D | ServerSocketChannelImpl.c | 112 if (errno != ECONNABORTED) { in Java_sun_nio_ch_ServerSocketChannelImpl_accept0() 120 if (errno == EAGAIN) in Java_sun_nio_ch_ServerSocketChannelImpl_accept0() 122 if (errno == EINTR) in Java_sun_nio_ch_ServerSocketChannelImpl_accept0()
|
D | PollArrayWrapper.c | 38 } while((_result == -1) && (errno == EINTR)); \ 54 if (res < 0 && errno == EINTR) { in ipoll()
|
D | SocketChannelImpl.c | 77 errno = 0; in Java_sun_nio_ch_SocketChannelImpl_checkConnect() 80 handleSocketError(env, errno); in Java_sun_nio_ch_SocketChannelImpl_checkConnect()
|
D | SocketInputStream.c | 102 if (errno == EBADF) { in SocketInputStream_socketRead0() 124 switch (errno) { in SocketInputStream_socketRead0()
|
D | FileInputStream.c | 80 if (errno == ESPIPE) { in FileInputStream_skip0() 108 if (errno == ENOTTY) { in available()
|
/libcore/luni/src/main/java/libcore/io/ |
D | IoBridge.java | 72 if (errnoException.errno == ENOTTY) { in available() 101 if (errnoException.errno == EADDRINUSE || errnoException.errno == EADDRNOTAVAIL || in bind() 102 errnoException.errno == EPERM || errnoException.errno == EACCES) { in bind() 131 if (errnoException.errno == EHOSTUNREACH) { in connect() 134 if (errnoException.errno == EADDRNOTAVAIL) { in connect() 172 if (errnoException.errno != EINPROGRESS) { in connectErrno() 275 if (cause.errno == ETIMEDOUT) { in isConnected() 507 if (errnoException.errno == EAGAIN) { in read() 566 if (errnoException.errno == ECONNREFUSED) { in maybeThrowAfterSendto() 570 if (errnoException.errno == EAGAIN) { in maybeThrowAfterSendto() [all …]
|
/libcore/luni/src/test/native/ |
D | libcore_java_io_FileTest.cpp | 39 jniThrowIOException(env, errno); in Java_libcore_java_io_FileTest_nativeTestFilesWithSurrogatePairs() 47 jniThrowIOException(env, errno); in Java_libcore_java_io_FileTest_nativeTestFilesWithSurrogatePairs()
|
/libcore/luni/src/test/java/libcore/libcore/io/ |
D | OsTest.java | 394 assertEquals("Expected EAFNOSUPPORT binding IPv4 socket to ::", EAFNOSUPPORT, expected.errno); in test_socketFamilies() 475 assertEquals(OsConstants.ENOENT, e.errno); in test_unlink() 494 if (OsConstants.ENOTCONN != expected.errno) { in test_recvfrom_concurrentShutdown() 529 assertEquals(OsConstants.ENODATA, e.errno); in test_xattr() 543 assertEquals(OsConstants.EEXIST, e.errno); in test_xattr() 557 assertEquals(OsConstants.ENODATA, e.errno); in test_xattr() 622 assertEquals(ENOENT, e.errno); in test_xattr_Errno() 628 assertEquals(ENOENT, e.errno); in test_xattr_Errno() 634 assertEquals(ENOENT, e.errno); in test_xattr_Errno() 640 assertEquals(ENOENT, e.errno); in test_xattr_Errno() [all …]
|