summaryrefslogtreecommitdiff
path: root/source3/libsmb/smberr.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/libsmb/smberr.c')
-rw-r--r--source3/libsmb/smberr.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/source3/libsmb/smberr.c b/source3/libsmb/smberr.c
index e6ecfefb34..00966aed43 100644
--- a/source3/libsmb/smberr.c
+++ b/source3/libsmb/smberr.c
@@ -193,3 +193,14 @@ char *werror_str(WERROR status)
slprintf(msg, sizeof(msg), "WIN32 code 0x%08x", W_ERROR_V(status));
return msg;
}
+
+
+/*****************************************************************************
+map a unix errno to a win32 error
+ *****************************************************************************/
+WERROR map_werror_from_unix(int error)
+{
+ NTSTATUS status = map_nt_error_from_unix(error);
+ return ntstatus_to_werror(status);
+}
+