diff options
Diffstat (limited to 'hw/dmx/config/dmxcompat.c')
-rw-r--r-- | hw/dmx/config/dmxcompat.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/hw/dmx/config/dmxcompat.c b/hw/dmx/config/dmxcompat.c index b4190ffcc..98c52eb0e 100644 --- a/hw/dmx/config/dmxcompat.c +++ b/hw/dmx/config/dmxcompat.c @@ -94,8 +94,7 @@ static void dmxVDLDisplayEntry(const char *buf, char *end; pt = strchr(buf, ' '); - strncpy(name, buf, pt-buf); - name[pt-buf] = '\0'; + strlcpy(name, buf, 1+pt-buf); *len = strlen(name); *x = strtol(pt, &end, 10); |