* sec_auth.cc (str2uni_cat): Move from here...

* path.cc (str2uni_cat): ...to here.  Simplify.  Make static inline.
	(get_nt_native_path): Use RtlAppendUnicodeToString rather than
	str2uni_cat for constant strings for speed.
	* security.h (str2uni_cat): Drop declaration.
This commit is contained in:
Corinna Vinschen
2009-05-09 15:08:16 +00:00
parent 4dff3fed7d
commit a22af4a956
4 changed files with 21 additions and 18 deletions

View File

@ -126,18 +126,6 @@ str2buf2lsa (LSA_STRING &tgt, char *buf, const char *srcstr)
memcpy (buf, srcstr, tgt.MaximumLength);
}
void
str2uni_cat (UNICODE_STRING &tgt, const char *srcstr)
{
int len = sys_mbstowcs (tgt.Buffer + tgt.Length / sizeof (WCHAR),
(tgt.MaximumLength - tgt.Length) / sizeof (WCHAR),
srcstr);
if (len)
tgt.Length += (len - 1) * sizeof (WCHAR);
else
tgt.Length = tgt.MaximumLength = 0;
}
HANDLE
open_local_policy (ACCESS_MASK access)
{