[PATCH 11/12] LookupAccountNameW() - refactor to eliminate code duplication

Paul Bryan Roberts pbronline-wine at yahoo.co.uk
Mon Oct 20 18:06:45 CDT 2008

LookupAccountNameW() has a stubbed but non-empty, incomplete, buggy 
implementation.  It fails a number of unit tests but Wine code relies on 

This is series of patches that provide what may be a reasonable first 
pass implementation of LookupAccountNameA() and LookupAccountNameW() that:

   - passes existing units tests for LookupAccountName
   - works for well known SIDs
   - works for 'first user account'
   - allows progress towards the resolution of Bug 14334

 From the beginning it was clear the the well-known and not so 
well-known SID cases were not entirely disjoint in terms of how they 
returned information.  Each patch tried to make this clear.  The 
previous patch fixed the last of the failing conformance test so now it 
is possible to rearrange the implementation to eliminate the code 

The old fixme becomes a trace and new fixmes mark the not yet handled cases.

This patch also replace strlen() et al with lstrlen().  Dunno if that's 
a good idea.

What this patch does not do is change the order.  The implementation 
checks for the first user account after checking all well known SIDs.  
Not very efficient - turn on trace to see why.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0011-LookupAccountNameW-refactor-to-eliminate-code-du.patch
Type: text/x-diff
Size: 0 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20081021/96a31b4c/attachment-0001.patch 

More information about the wine-patches mailing list