[libvirt] [PATCH] Do not unlink sanlock lockspace if registering with sanlock daemon returns error

This is a patch for bug 847848 If registering an existing lockspace with the sanlock daemon returns an error, libvirt should not proceed to unlink the lockspace. Signed-off-by: Asad Saeed <asad.saeed@acidseed.com> --- src/locking/lock_driver_sanlock.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/locking/lock_driver_sanlock.c b/src/locking/lock_driver_sanlock.c index 9ec99dd..f046102 100644 --- a/src/locking/lock_driver_sanlock.c +++ b/src/locking/lock_driver_sanlock.c @@ -242,7 +242,7 @@ static int virLockManagerSanlockSetupLockspace(void) virReportSystemError(-rv, _("Unable to add lockspace %s"), path); - goto error_unlink; + goto error; } else { VIR_DEBUG("Lockspace %s is already registered", path); } -- 1.7.1

On 08/13/2012 02:21 PM, Asad Saeed wrote: Subject line is a bit long (80 columns); we prefer closer to a max of 60, for use with 'git shortlog'. I changed to: sanlock: don't unlink lockspace if registration fails
This is a patch for bug 847848 If registering an existing lockspace with the sanlock daemon returns an error, libvirt should not proceed to unlink the lockspace.
Signed-off-by: Asad Saeed <asad.saeed@acidseed.com> --- src/locking/lock_driver_sanlock.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
ACK and pushed. I added you to AUTHORS, let me know if you prefer any spelling adjustments to name or email. -- Eric Blake eblake@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
participants (2)
-
Asad Saeed
-
Eric Blake