[ros-diffs] [arty] 14624: Use DriverDesc in the registry as the
adapter name since the ndis name OID
Alex Ionescu
ionucu at videotron.ca
Fri Apr 15 08:31:18 CEST 2005
arty at svn.reactos.com wrote:
>
>+NTSTATUS NTAPI AppendUnicodeString(PUNICODE_STRING ResultFirst,
>+ PUNICODE_STRING Second,
>+ BOOL Deallocate) {
>+ NTSTATUS Status;
>+ UNICODE_STRING Ustr = *ResultFirst;
>+ PWSTR new_string = ExAllocatePoolWithTag
>+ (PagedPool,
>+ (ResultFirst->Length + Second->Length + sizeof(WCHAR)), TAG_STRING);
>+ if( !new_string ) {
>+ return STATUS_NO_MEMORY;
>+ }
>+ memcpy( new_string, ResultFirst->Buffer, ResultFirst->Length );
>+ memcpy( new_string + ResultFirst->Length / sizeof(WCHAR),
>+ Second->Buffer, Second->Length );
>+ if( Deallocate ) RtlFreeUnicodeString(ResultFirst);
>+ ResultFirst->Length = Ustr.Length + Second->Length;
>+ ResultFirst->MaximumLength = ResultFirst->Length;
>+ new_string[ResultFirst->Length / sizeof(WCHAR)] = 0;
>+ Status = RtlCreateUnicodeString(ResultFirst,new_string) ?
>+ STATUS_SUCCESS : STATUS_NO_MEMORY;
>+ ExFreePool(new_string);
>+ return Status;
>+}
>
>
>
What's wrong with
RtlAppendUnicodeStringToString ?
Best regards,
Alex Ionescu
More information about the Ros-diffs
mailing list