From 17b8c16000461c5b7908cdb3d923bba9a03122b5 Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Sat, 15 Nov 2008 17:05:19 +0000 Subject: [PATCH] windows-error-mapping-20081115 LICENSE MIT do not map success (0) to an error --- src/WINNT/afsd/smb.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/WINNT/afsd/smb.c b/src/WINNT/afsd/smb.c index 7fbb59e39..ece4ff4c3 100644 --- a/src/WINNT/afsd/smb.c +++ b/src/WINNT/afsd/smb.c @@ -2989,7 +2989,10 @@ void smb_MapNTError(long code, unsigned long *NTStatusp) /* map CM_ERROR_* errors to NT 32-bit status codes */ /* NT Status codes are listed in ntstatus.h not winerror.h */ - if (code == CM_ERROR_NOSUCHCELL) { + if (code == 0) { + NTStatus = 0; + } + else if (code == CM_ERROR_NOSUCHCELL) { NTStatus = 0xC000000FL; /* No such file */ } else if (code == CM_ERROR_NOSUCHVOLUME) { -- 2.39.5