mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-05 09:17:44 +03:00
sd-journal: check retval of sd_id128_from_string call
Fixes: CID#1469712
CID 1469712 (#1 of 1): Unused value (UNUSED_VALUE)
returned_value: Assigning value from sd_id128_from_string(word + 2, &boot_id) to r here,
but that stored value is overwritten before it can be used.
(cherry picked from commit c9f5ac0917
)
This commit is contained in:
parent
18517e849c
commit
73a327d2f4
@ -990,6 +990,8 @@ _public_ int sd_journal_seek_cursor(sd_journal *j, const char *cursor) {
|
||||
case 'b':
|
||||
boot_id_set = true;
|
||||
r = sd_id128_from_string(word + 2, &boot_id);
|
||||
if (r < 0)
|
||||
return r;
|
||||
break;
|
||||
|
||||
case 'm':
|
||||
|
Loading…
Reference in New Issue
Block a user