mirror of
https://github.com/clearlinux/systemd-stable.git
synced 2026-10-04 07:48:36 +00:00
bus: convert a bus error with NULL name into an errno of 0 in sd_bus_error_get_errno()
This commit is contained in:
@@ -285,6 +285,9 @@ _public_ int sd_bus_error_get_errno(const sd_bus_error* e) {
|
||||
if (!e)
|
||||
return 0;
|
||||
|
||||
if (!e->name)
|
||||
return 0;
|
||||
|
||||
return bus_error_name_to_errno(e->name);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user