wininet: Compare HRESULT values explicitly against S_OK instead of using an implicit != 0 comparison.

This commit is contained in:
Rob Shearman 2008-10-01 11:20:49 +01:00 committed by Alexandre Julliard
parent ee2281d370
commit d31ce9ae37
1 changed files with 2 additions and 2 deletions

View File

@ -1948,7 +1948,7 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(LPWININETHTTPSESSIONW lpwhs,
lpwhr->lpszPath = HeapAlloc(GetProcessHeap(), 0, len*sizeof(WCHAR));
rc = UrlEscapeW(lpszObjectName, lpwhr->lpszPath, &len,
URL_ESCAPE_SPACES_ONLY);
if (rc)
if (rc != S_OK)
{
ERR("Unable to escape string!(%s) (%d)\n",debugstr_w(lpszObjectName),rc);
strcpyW(lpwhr->lpszPath,lpszObjectName);
@ -3045,7 +3045,7 @@ static BOOL HTTP_HandleRedirect(LPWININETHTTPREQW lpwhr, LPCWSTR lpszUrl)
lpwhr->lpszPath = HeapAlloc(GetProcessHeap(), 0, needed*sizeof(WCHAR));
rc = UrlEscapeW(path, lpwhr->lpszPath, &needed,
URL_ESCAPE_SPACES_ONLY);
if (rc)
if (rc != S_OK)
{
ERR("Unable to escape string!(%s) (%d)\n",debugstr_w(path),rc);
strcpyW(lpwhr->lpszPath,path);