diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/libsystemd-id128/sd-id128.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libsystemd-id128/sd-id128.c b/src/libsystemd-id128/sd-id128.c index 4286ae7d14..68c4987149 100644 --- a/src/libsystemd-id128/sd-id128.c +++ b/src/libsystemd-id128/sd-id128.c @@ -170,6 +170,9 @@ _public_ int sd_id128_get_boot(sd_id128_t *ret) { for (j = 0, p = buf; j < 16; j++) { int a, b; + if (p >= buf + k) + return -EIO; + if (*p == '-') p++; |