HomeClusterLabs Projects

Low: fencer: always add device ID to device addition notification

Description

Low: fencer: always add device ID to device addition notification

When a device addition request comes into the fencer,
handle_device_add_request() processes it and sends a notification with the
result.

The notification also includes the device ID from the request, but it was not
set for every possible error case. It was only set if stonith_device_register()
was called, not for unprivileged requests, and wasn't even set by that function
on early errors.

Now, handle_device_add_request() grabs the device XML and ID, and passes that
XML to stonith_device_register() -> build_device_from_xml().

Details

Provenance
kgaillotAuthored on Mar 8 2022, 3:59 PM
Parents
rP3a7fd0a5caa4: Fix: fencer: avoid memory leaks when processing topology requests
Branches
Unknown
Tags
Unknown