summaryrefslogtreecommitdiffstats
path: root/src/nolo.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nolo.c')
-rw-r--r--src/nolo.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nolo.c b/src/nolo.c
index e247698..9ba5a06 100644
--- a/src/nolo.c
+++ b/src/nolo.c
@@ -176,7 +176,8 @@ static int nolo_get_version_string(struct usb_device_info * dev, const char * st
if ( strlen(str) > 500 )
return -1;
- sprintf(buf, "version:%s", str);
+ if ( sprintf(buf, "version:%s", str) <= 0 )
+ return -1;
ret = nolo_get_string(dev, buf, out, size);