Commit 787bd63
dm mpath: Add missing dm_put_device when failing to get scsi dh name
When commit fd81bc5 ("scsi: device_handler: Return error pointer in
scsi_dh_attached_handler_name()") added code to fail parsing the path if
scsi_dh_attached_handler_name() failed with -ENOMEM, it didn't clean up
the reference to the path device that had just been taken. Fix this, and
steamline the error paths of parse_path() a little.
Fixes: fd81bc5 ("scsi: device_handler: Return error pointer in scsi_dh_attached_handler_name()")
Cc: stable@vger.kernel.org
Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>1 parent ec85340 commit 787bd63
1 file changed
Lines changed: 10 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
960 | 960 | | |
961 | 961 | | |
962 | 962 | | |
963 | | - | |
| 963 | + | |
| 964 | + | |
964 | 965 | | |
965 | 966 | | |
966 | 967 | | |
967 | 968 | | |
968 | 969 | | |
969 | 970 | | |
970 | | - | |
971 | | - | |
972 | | - | |
973 | | - | |
| 971 | + | |
| 972 | + | |
974 | 973 | | |
975 | 974 | | |
976 | 975 | | |
977 | | - | |
978 | | - | |
979 | | - | |
980 | | - | |
| 976 | + | |
| 977 | + | |
981 | 978 | | |
982 | 979 | | |
983 | | - | |
| 980 | + | |
| 981 | + | |
| 982 | + | |
| 983 | + | |
984 | 984 | | |
985 | 985 | | |
986 | 986 | | |
| |||
0 commit comments