aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDuncaen <mail@duncano.de>2018-01-19 12:46:43 +0100
committerDuncaen <mail@duncano.de>2018-01-19 12:46:43 +0100
commitab6f83dbda1f261a95dcd2c56bcfe50e025bfd20 (patch)
tree272fa3cef3d918119067ce4fa80040db87fdbdee
parent1859161743bf93fc652378626824e1f0024e33d1 (diff)
downloaddotfiles-ab6f83dbda1f261a95dcd2c56bcfe50e025bfd20.tar.gz
bin/errstr: initial import for linux
-rwxr-xr-xbin/errstr97
1 files changed, 97 insertions, 0 deletions
diff --git a/bin/errstr b/bin/errstr
new file mode 100755
index 0000000..97a8b6b
--- /dev/null
+++ b/bin/errstr
@@ -0,0 +1,97 @@
+#!/bin/sh
+# errstr errno... - print error string
+
+for e in $@; do
+ case "$e" in
+ 1) printf "%s\n" "Operation not permitted" ;;
+ 2) printf "%s\n" "No such file or directory" ;;
+ 3) printf "%s\n" "No such process" ;;
+ 4) printf "%s\n" "Interrupted system call" ;;
+ 5) printf "%s\n" "I/O error" ;;
+ 6) printf "%s\n" "No such device or address" ;;
+ 7) printf "%s\n" "Argument list too long" ;;
+ 8) printf "%s\n" "Exec format error" ;;
+ 9) printf "%s\n" "Bad file descriptor" ;;
+ 10) printf "%s\n" "No child process" ;;
+ 11) printf "%s\n" "Resource temporarily unavailable" ;;
+ 12) printf "%s\n" "Out of memory" ;;
+ 13) printf "%s\n" "Permission denied" ;;
+ 14) printf "%s\n" "Bad address" ;;
+ 15) printf "%s\n" "Block device required" ;;
+ 16) printf "%s\n" "Resource busy" ;;
+ 17) printf "%s\n" "File exists" ;;
+ 18) printf "%s\n" "Cross-device link" ;;
+ 19) printf "%s\n" "No such device" ;;
+ 20) printf "%s\n" "Not a directory" ;;
+ 21) printf "%s\n" "Is a directory" ;;
+ 22) printf "%s\n" "Invalid argument" ;;
+ 23) printf "%s\n" "Too many open files in system" ;;
+ 24) printf "%s\n" "No file descriptors available" ;;
+ 25) printf "%s\n" "Not a tty" ;;
+ 26) printf "%s\n" "Text file busy" ;;
+ 27) printf "%s\n" "File too large" ;;
+ 28) printf "%s\n" "No space left on device" ;;
+ 29) printf "%s\n" "Invalid seek" ;;
+ 30) printf "%s\n" "Read-only file system" ;;
+ 31) printf "%s\n" "Too many links" ;;
+ 32) printf "%s\n" "Broken pipe" ;;
+ 33) printf "%s\n" "Domain error" ;;
+ 34) printf "%s\n" "Result not representable" ;;
+ 35) printf "%s\n" "Resource deadlock would occur" ;;
+ 36) printf "%s\n" "Filename too long" ;;
+ 37) printf "%s\n" "No locks available" ;;
+ 38) printf "%s\n" "Function not implemented" ;;
+ 39) printf "%s\n" "Directory not empty" ;;
+ 40) printf "%s\n" "Symbolic link loop" ;;
+ 11) printf "%s\n" "Resource temporarily unavailable" ;;
+ 42) printf "%s\n" "No message of desired type" ;;
+ 43) printf "%s\n" "Identifier removed" ;;
+ 60) printf "%s\n" "Device not a stream" ;;
+ 61) printf "%s\n" "No data available" ;;
+ 62) printf "%s\n" "Device timeout" ;;
+ 63) printf "%s\n" "Out of streams resources" ;;
+ 67) printf "%s\n" "Link has been severed" ;;
+ 71) printf "%s\n" "Protocol error" ;;
+ 74) printf "%s\n" "Bad message" ;;
+ 75) printf "%s\n" "Value too large for data type" ;;
+ 77) printf "%s\n" "File descriptor in bad state" ;;
+ 84) printf "%s\n" "Illegal byte sequence" ;;
+ 88) printf "%s\n" "Not a socket" ;;
+ 89) printf "%s\n" "Destination address required" ;;
+ 90) printf "%s\n" "Message too large" ;;
+ 91) printf "%s\n" "Protocol wrong type for socket" ;;
+ 92) printf "%s\n" "Protocol not available" ;;
+ 93) printf "%s\n" "Protocol not supported" ;;
+ 94) printf "%s\n" "Socket type not supported" ;;
+ 95) printf "%s\n" "Not supported" ;;
+ 95) printf "%s\n" "Not supported" ;;
+ 96) printf "%s\n" "Protocol family not supported" ;;
+ 97) printf "%s\n" "Address family not supported by protocol" ;;
+ 98) printf "%s\n" "Address in use" ;;
+ 99) printf "%s\n" "Address not available" ;;
+ 100) printf "%s\n" "Network is down" ;;
+ 101) printf "%s\n" "Network unreachable" ;;
+ 102) printf "%s\n" "Connection reset by network" ;;
+ 103) printf "%s\n" "Connection aborted" ;;
+ 104) printf "%s\n" "Connection reset by peer" ;;
+ 105) printf "%s\n" "No buffer space available" ;;
+ 106) printf "%s\n" "Socket is connected" ;;
+ 107) printf "%s\n" "Socket not connected" ;;
+ 108) printf "%s\n" "Cannot send after socket shutdown" ;;
+ 110) printf "%s\n" "Operation timed out" ;;
+ 111) printf "%s\n" "Connection refused" ;;
+ 112) printf "%s\n" "Host is down" ;;
+ 113) printf "%s\n" "Host is unreachable" ;;
+ 114) printf "%s\n" "Operation already in progress" ;;
+ 115) printf "%s\n" "Operation in progress" ;;
+ 116) printf "%s\n" "Stale file handle" ;;
+ 121) printf "%s\n" "Remote I/O error" ;;
+ 122) printf "%s\n" "Quota exceeded" ;;
+ 123) printf "%s\n" "No medium found" ;;
+ 124) printf "%s\n" "Wrong medium type" ;;
+ 125) printf "%s\n" "Operation canceled" ;;
+ 130) printf "%s\n" "Previous owner died" ;;
+ 131) printf "%s\n" "State not recoverable" ;;
+ *) printf "%s\n" "No error information" ;;
+ esac
+done