Author: ekohl
Date: Sat Jul 27 18:53:52 2013
New Revision: 59590
URL:
http://svn.reactos.org/svn/reactos?rev=59590&view=rev
Log:
[NETAPI32]
NetpNtStatusToApiStatus: Map STATUS_INVALID_ACCOUNT_NAME to NERR_BadUsername.
Modified:
trunk/reactos/dll/win32/netapi32/netapi32.c
Modified: trunk/reactos/dll/win32/netapi32/netapi32.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/netapi32/netapi3…
==============================================================================
--- trunk/reactos/dll/win32/netapi32/netapi32.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/netapi32/netapi32.c [iso-8859-1] Sat Jul 27 18:53:52 2013
@@ -218,7 +218,24 @@
WINAPI
NetpNtStatusToApiStatus(NTSTATUS Status)
{
- return RtlNtStatusToDosError(Status);
+ NET_API_STATUS ApiStatus;
+
+ switch (Status)
+ {
+ case STATUS_SUCCESS:
+ ApiStatus = NERR_Success;
+ break;
+
+ case STATUS_INVALID_ACCOUNT_NAME:
+ ApiStatus = NERR_BadUsername;
+ break;
+
+ default:
+ ApiStatus = RtlNtStatusToDosError(Status);
+ break;
+ }
+
+ return ApiStatus;
}
NET_API_STATUS WINAPI NetUseEnum(LMSTR server, DWORD level, LPBYTE* bufptr, DWORD
prefmaxsize,