[pve-devel] [Patch storage 2/2] Improve error message.

Wolfgang Link w.link at proxmox.com
Fri May 18 10:26:21 CEST 2018


Now we get all errors from the cifs client
and also if the client program fails.

---
 PVE/Storage/CIFSPlugin.pm | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/PVE/Storage/CIFSPlugin.pm b/PVE/Storage/CIFSPlugin.pm
index 724fb1f..c1a0a0d 100644
--- a/PVE/Storage/CIFSPlugin.pm
+++ b/PVE/Storage/CIFSPlugin.pm
@@ -218,9 +218,8 @@ sub check_connection {
     };
 
     if (my $err = $@) {
-	die "$out_str\n" if defined($out_str) &&
-	    ($out_str =~ m/NT_STATUS_ACCESS_DENIED/);
-	return 0;
+	return $out_str if defined($out_str);
+	return $err;
     }
 
     return 1;
-- 
2.11.0




More information about the pve-devel mailing list