diff options
author | Pete Batard <pete@akeo.ie> | 2012-05-07 15:41:50 +0100 |
---|---|---|
committer | Pete Batard <pete@akeo.ie> | 2012-05-08 11:01:42 +0100 |
commit | 00d6fed8f26418b00ab9177d67d53af7328ec127 (patch) | |
tree | c0e34293c8fa5d4155cf935d09c7ebe7e12b7229 | |
parent | d190bd7887ba7aba5949704592d5a18680e8a2df (diff) | |
download | libusb-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.c | 3 | ||||
-rw-r--r-- | libusb/version.h | 2 |
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 |