aboutsummaryrefslogtreecommitdiffstats
path: root/libusb/strerror.c
Commit message (Collapse)AuthorAgeFilesLines
* fixed some clang -Wdocumentation warnings from bad doxygen markupSean McBride2013-07-301-1/+1
|
* Core: fix another compiler warning in libusb_setlocale()Pete Batard2013-06-191-1/+1
| | | | | * VS2012 (64 bit) produces the following in strerror.c(156): warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data
* Core: fix compiler warning in libusb_setlocale()Ludovic Rousseau2013-06-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Hello, A small patch for: strerror.c: In function 'libusb_setlocale': strerror.c:148: warning: comparison between signed and unsigned strerror.c:152: warning: comparison between signed and unsigned -- Dr. Ludovic Rousseau From a4144845845cd0a06fb9074ba2d6669ece3a5b1a Mon Sep 17 00:00:00 2001 From: Ludovic Rousseau <ludovic.rousseau+github@gmail.com> Date: Wed, 19 Jun 2013 13:16:31 +0200 Subject: [PATCH] Core: fix compiler warning in libusb_setlocale() strerror.c: In function 'libusb_setlocale': strerror.c:148: warning: comparison between signed and unsigned strerror.c:152: warning: comparison between signed and unsigned Signed-off-by: Hans de Goede <hdegoede@redhat.com>
* Core: Add a libusb_strerror() functionHans de Goede2013-06-101-0/+184
This patch adds the much requested libusb_strerror() function, taking into account all issues people raised wrt previous attempts. Criteria / Decisions underlying this implementation: - Must support translated messages - Must not use gettext as that does not work well in combination with Windows (when building with Visual C, or for Windows CE) - API compatible with FreeBSD and various patched libusb-s floating around - KISS: - Do not add any (other) library dependencies - Do not try to deal with message encodings (iconv), simply always return UTF-8 making encoding the problem of the application using libusb_strerror. - Defaults to English, so apps which don't want translated messages, don't need to do anything special - Defaults to English (with pure ASCII messages), so apps which don't call libusb_setlocale() don't need to worry about encoding