diff mbox

[09/12] orphan paths on failed add

Message ID 1404105243-5071-10-git-send-email-bmarzins@redhat.com (mailing list archive)
State Accepted, archived
Delegated to: christophe varoqui
Headers show

Commit Message

Benjamin Marzinski June 30, 2014, 5:14 a.m. UTC
When multipathd tries to add a path but fails doing the table reload, it
wasn't orphaning the path.  This can cause problems later if multipathd
tries to switch the pathgroup of this path which isn't actually part of
the multipath device.

Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
---
 multipathd/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Christophe Varoqui July 24, 2014, 8:45 a.m. UTC | #1
Applied,
Thanks


On Mon, Jun 30, 2014 at 7:14 AM, Benjamin Marzinski <bmarzins@redhat.com>
wrote:

> When multipathd tries to add a path but fails doing the table reload, it
> wasn't orphaning the path.  This can cause problems later if multipathd
> tries to switch the pathgroup of this path which isn't actually part of
> the multipath device.
>
> Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
> ---
>  multipathd/main.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/multipathd/main.c b/multipathd/main.c
> index 337bfe9..3afed62 100644
> --- a/multipathd/main.c
> +++ b/multipathd/main.c
> @@ -561,7 +561,7 @@ rescan:
>                 return 0;
>         }
>         else
> -               return 1;
> +               goto fail;
>
>  fail_map:
>         remove_map(mpp, vecs, 1);
> --
> 1.8.3.1
>
>
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel
diff mbox

Patch

diff --git a/multipathd/main.c b/multipathd/main.c
index 337bfe9..3afed62 100644
--- a/multipathd/main.c
+++ b/multipathd/main.c
@@ -561,7 +561,7 @@  rescan:
 		return 0;
 	}
 	else
-		return 1;
+		goto fail;
 
 fail_map:
 	remove_map(mpp, vecs, 1);