diff options
author | Pali Rohár <pali.rohar@gmail.com> | 2012-11-25 20:49:10 +0100 |
---|---|---|
committer | Pali Rohár <pali.rohar@gmail.com> | 2012-11-25 20:49:10 +0100 |
commit | cffeb329c4fa3863af83a2ea1dbf53ba01627059 (patch) | |
tree | 6ff0a5ba8d98d78f0e7ccb0a0ad2697c9c071d8c /libusb/error.c | |
parent | 4f6eb6e936a80432270c3e11c43fe0894aed87e9 (diff) | |
download | 0xFFFF-cffeb329c4fa3863af83a2ea1dbf53ba01627059.tar.bz2 |
Remove libusb from tree
Diffstat (limited to 'libusb/error.c')
-rw-r--r-- | libusb/error.c | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/libusb/error.c b/libusb/error.c deleted file mode 100644 index f7d496d..0000000 --- a/libusb/error.c +++ /dev/null @@ -1,36 +0,0 @@ -/* - * USB Error messages - * - * Copyright (c) 2000-2001 Johannes Erdfelt <johannes@erdfelt.com> - * - * This library is covered by the LGPL, read LICENSE for details. - */ - -#include <errno.h> -#include <string.h> - -#include "usb.h" -#include "error.h" - -char usb_error_str[1024] = ""; -int usb_error_errno = 0; -usb_error_type_t usb_error_type = USB_ERROR_TYPE_NONE; - -char *usb_strerror(void) -{ - switch (usb_error_type) { - case USB_ERROR_TYPE_NONE: - return "No error"; - case USB_ERROR_TYPE_STRING: - return usb_error_str; - case USB_ERROR_TYPE_ERRNO: - if (usb_error_errno > -USB_ERROR_BEGIN) - return strerror(usb_error_errno); - else - /* Any error we don't know falls under here */ - return "Unknown error"; - } - - return "Unknown error"; -} - |