[PATCH 06/12] LookupAccountNameW() - use CreateWellKnowenSid() properly

Paul Bryan Roberts pbronline-wine at yahoo.co.uk
Mon Oct 20 18:05:22 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

This patch also amends the handling of well-know-SIDs to use 
CreateWellKnownSid() correctly.

LookupAccountName() can be called with a NULL SID pointer to find out 
how big a SID the routine would return otherwise.  CreateWellKnownSid() 
cannot be used this way.

So, CreateWellKnownSid() must be a passed a maximum sized side.  This is 
allocated from heap memory instead of the stack.  The real reason for 
this will become clear later in the series.

This patch is conformance test neutral.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0006-LookupAccountNameW-use-CreateWellKnowenSid-pro.patch
Type: text/x-diff
Size: 0 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20081021/d0576a4e/attachment.patch 

More information about the wine-patches mailing list