summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPete Batard <pete@akeo.ie>2012-05-07 15:41:50 +0100
committerPete Batard <pete@akeo.ie>2012-05-08 11:01:42 +0100
commit00d6fed8f26418b00ab9177d67d53af7328ec127 (patch)
treec0e34293c8fa5d4155cf935d09c7ebe7e12b7229
parentd190bd7887ba7aba5949704592d5a18680e8a2df (diff)
downloadlibusbx-00d6fed8f26418b00ab9177d67d53af7328ec127.tar.gz
Samples: fix strcat vs strlcat warning on OpenBSD
* Without this, OpenBSD produces the following warning: strcat() is almost always misused, please use strlcat()
-rw-r--r--examples/xusb.c3
-rw-r--r--libusb/version.h2
2 files changed, 2 insertions, 3 deletions
diff --git a/examples/xusb.c b/examples/xusb.c
index a98ebb4..c811353 100644
--- a/examples/xusb.c
+++ b/examples/xusb.c
@@ -54,7 +54,7 @@
// Global variables
bool binary_dump = false;
-char binary_name[64];
+char binary_name[64] = "raw.bin";
static int perr(char const *format, ...)
{
@@ -778,7 +778,6 @@ int main(int argc, char** argv)
debug_mode = true;
break;
case 'b':
- strcat(binary_name, "raw.bin");
if (j+1 < argc) {
strncpy(binary_name, argv[j+1], 64);
j++;
diff --git a/libusb/version.h b/libusb/version.h
index 18a8f90..704ac39 100644
--- a/libusb/version.h
+++ b/libusb/version.h
@@ -9,7 +9,7 @@
#define LIBUSB_MICRO 11
#endif
#ifndef LIBUSB_NANO
-#define LIBUSB_NANO 10494
+#define LIBUSB_NANO 10495
#endif
/* LIBUSB_RC is the release candidate suffix. Should normally be empty. */
#ifndef LIBUSB_RC