http://bugs.winehq.org/show_bug.cgi?id=8425
------- Additional Comments From dmitry@codeweavers.com 2007-17-05 21:43 ------- SetLastError(0xdeadbeef); memset(bufW, 'x', sizeof(bufW)); len = MultiByteToWideChar(CP_ACP, 0, "foobar", -1, bufW, 6); ok(len == 0 && GetLastError() == ERROR_INSUFFICIENT_BUFFER, "MultiByteToWideChar(-1): len=%d error=%u\n", len, GetLastError());
Simple test above confirms that behaviour of MultiByteToWideChar is correct.