Le 02/08/2016 à 14:06, Nikolay Sivov a écrit :
On 02.08.2016 14:31, Pierre Schweitzer wrote:
This fixes a bug seen during review for ReactOS commit: in case of local redirection, the name wasn't properly converted back to ANSI for A callers.
-static void use_connection_set_accessnameW(struct use_connection_context *ctxt) +static void use_connection_set_accessnameW(struct use_connection_context *ctxt, WCHAR *local_name) { WCHAR *accessname = ctxt->accessname;
- if (ctxt->resource->lpLocalName)
strcpyW(accessname, ctxt->resource->lpLocalName);
- if (local_name)
else strcpyW(accessname, ctxt->resource->lpRemoteName);strcpyW(accessname, local_name);
}
You already have lpLocalName here, why another argument?
Because lpLocalName isn't necessarily set to the correct value in case of automatic redirection. It was asked by A. Julliard: not to modify context resource.