Kai Blin : netapi32: Get rid of an ugly macro definition only used once.
Module: wine Branch: master Commit: 5f8a14d5e2e38882a804d6c3634562be48e314ea URL: http://source.winehq.org/git/wine.git/?a=commit;h=5f8a14d5e2e38882a804d6c363... Author: Kai Blin <kai.blin(a)gmail.com> Date: Sun Mar 18 22:13:28 2007 +0100 netapi32: Get rid of an ugly macro definition only used once. --- dlls/netapi32/access.c | 15 ++++++--------- 1 files changed, 6 insertions(+), 9 deletions(-) diff --git a/dlls/netapi32/access.c b/dlls/netapi32/access.c index 49a6d26..f63a35c 100644 --- a/dlls/netapi32/access.c +++ b/dlls/netapi32/access.c @@ -88,14 +88,6 @@ static BOOL NETAPI_IsKnownUser(LPCWSTR UserName) return Result; } -#define NETAPI_ForceKnownUser(UserName, FailureCode) \ - if (!NETAPI_IsKnownUser(UserName)) \ - { \ - TRACE("Can't find information for user %s\n", \ - debugstr_w(UserName)); \ - return FailureCode; \ - } - /************************************************************ * NetUserAdd (NETAPI32.@) */ @@ -152,7 +144,12 @@ NetUserGetInfo(LPCWSTR servername, LPCWSTR username, DWORD level, if (status != NERR_Success) return status; NETAPI_ForceLocalComputer(servername, NERR_InvalidComputer); - NETAPI_ForceKnownUser(username, NERR_UserNotFound); + + if(!NETAPI_IsKnownUser(username)) + { + TRACE("User %s is unknown.\n", debugstr_w(username)); + return NERR_UserNotFound; + } switch (level) {
participants (1)
-
Alexandre Julliard