Commit ea05a257 authored by Lei Zhang's avatar Lei Zhang Committed by Alexandre Julliard

shlwapi: Fix a return value in UrlEscapeA.

parent 43bff70a
...@@ -480,9 +480,7 @@ static void test_UrlEscape(void) ...@@ -480,9 +480,7 @@ static void test_UrlEscape(void)
size = 1; size = 1;
ret = UrlEscapeA("/woningplan/woonkamer basis.swf", empty_string, &size, URL_ESCAPE_SPACES_ONLY); ret = UrlEscapeA("/woningplan/woonkamer basis.swf", empty_string, &size, URL_ESCAPE_SPACES_ONLY);
todo_wine { ok(ret == E_POINTER, "got %x, expected %x\n", ret, E_POINTER);
ok(ret == E_POINTER, "got %x, expected %x\n", ret, E_POINTER);
}
ok(size == 34, "got %d, expected %d\n", size, 34); ok(size == 34, "got %d, expected %d\n", size, 34);
for(i=0; i<sizeof(TEST_ESCAPE)/sizeof(TEST_ESCAPE[0]); i++) { for(i=0; i<sizeof(TEST_ESCAPE)/sizeof(TEST_ESCAPE[0]); i++) {
......
...@@ -860,7 +860,7 @@ HRESULT WINAPI UrlEscapeA( ...@@ -860,7 +860,7 @@ HRESULT WINAPI UrlEscapeA(
*pcchEscaped = lenA; *pcchEscaped = lenA;
} else { } else {
*pcchEscaped = lenA + 1; *pcchEscaped = lenA + 1;
ret = E_INVALIDARG; ret = E_POINTER;
} }
} }
if(escapedW != bufW) HeapFree(GetProcessHeap(), 0, escapedW); if(escapedW != bufW) HeapFree(GetProcessHeap(), 0, escapedW);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment