diff options
author | Peter Stuge <peter@stuge.se> | 2011-02-27 06:59:15 +0100 |
---|---|---|
committer | Peter Stuge <peter@stuge.se> | 2011-06-13 22:06:30 +0200 |
commit | 4be84ab49c838d534d3a1b8a64ffa89774984ee7 (patch) | |
tree | ac06e20fc1fef1c18266fd5ae98f4de77d13798a /libusb/core.c | |
parent | 0e177f22fcc69d9aab6fb410e85f3413f478c94c (diff) | |
download | libusbx-4be84ab49c838d534d3a1b8a64ffa89774984ee7.tar.gz |
Revert libusb_strerror() until we have i18n and l10n
Diffstat (limited to 'libusb/core.c')
-rw-r--r-- | libusb/core.c | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/libusb/core.c b/libusb/core.c index 64445ab..6605c96 100644 --- a/libusb/core.c +++ b/libusb/core.c @@ -1662,53 +1662,3 @@ void usbi_log(struct libusb_context *ctx, enum usbi_log_level level, usbi_log_v(ctx, level, function, format, args); va_end (args); } - -/** \ingroup misc - * Returns a constant NULL-terminated string with an English short description - * of the given error code. The caller should never free() the returned pointer - * since it points to a constant string. - * The returned string is encoded in ASCII form and always starts with a - * capital letter and ends without any punctuation. - * Future versions of libusb may return NULL if the library is compiled without - * these messages included (e.g. for embedded systems). - * This function is intended to be used for debugging purposes only. - * - * \param errcode the error code whose description is desired - * \returns a short description of the error code in English, or NULL if the - * error descriptions are unavailable - */ -DEFAULT_VISIBILITY -const char * LIBUSB_CALL libusb_strerror(enum libusb_error errcode) -{ - switch (errcode) { - case LIBUSB_SUCCESS: - return "Success"; - case LIBUSB_ERROR_IO: - return "Input/output error"; - case LIBUSB_ERROR_INVALID_PARAM: - return "Invalid parameter"; - case LIBUSB_ERROR_ACCESS: - return "Access denied (insufficient permissions)"; - case LIBUSB_ERROR_NO_DEVICE: - return "No such device (it may have been disconnected)"; - case LIBUSB_ERROR_NOT_FOUND: - return "Entity not found"; - case LIBUSB_ERROR_BUSY: - return "Resource busy"; - case LIBUSB_ERROR_TIMEOUT: - return "Operation timed out"; - case LIBUSB_ERROR_OVERFLOW: - return "Overflow"; - case LIBUSB_ERROR_PIPE: - return "Pipe error"; - case LIBUSB_ERROR_INTERRUPTED: - return "System call interrupted (perhaps due to signal)"; - case LIBUSB_ERROR_NO_MEM: - return "Insufficient memory"; - case LIBUSB_ERROR_NOT_SUPPORTED: - return "Operation not supported or unimplemented on this platform"; - case LIBUSB_ERROR_OTHER: - return "Other error"; - } - return "Unknown error"; -} |