summaryrefslogtreecommitdiff
path: root/driver_ubx.c
diff options
context:
space:
mode:
Diffstat (limited to 'driver_ubx.c')
-rw-r--r--driver_ubx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/driver_ubx.c b/driver_ubx.c
index 25b4ecf2..616dcac7 100644
--- a/driver_ubx.c
+++ b/driver_ubx.c
@@ -343,7 +343,7 @@ static void ubx_msg_inf(struct gps_device_t *session, unsigned char *buf, size_t
if (data_len > MAX_PACKET_LENGTH - 1)
data_len = MAX_PACKET_LENGTH - 1;
- (void)strlcpy(txtbuf, (char *)buf + UBX_PREFIX_LEN, MAX_PACKET_LENGTH);
+ (void)strlcpy(txtbuf, (char *)buf + UBX_PREFIX_LEN, sizeof(txtbuf));
txtbuf[data_len] = '\0';
switch (msgid) {
case UBX_INF_DEBUG: