HTTP_HttpSendRequestA: Remove \r and \n at the end of
lpwhr->lpszPath.
This commit is contained in:
parent
9063cefec5
commit
25efbc9dbc
|
@ -1348,7 +1348,12 @@ BOOL WINAPI HTTP_HttpSendRequestA(HINTERNET hHttpRequest, LPCSTR lpszHeaders,
|
|||
/* If we don't have a path we set it to root */
|
||||
if (NULL == lpwhr->lpszPath)
|
||||
lpwhr->lpszPath = WININET_strdup("/");
|
||||
|
||||
else /* remove \r and \n*/
|
||||
{
|
||||
int nLen = strlen(lpwhr->lpszPath);
|
||||
while ((nLen > 0) && ((lpwhr->lpszPath[nLen-1] == '\r')||(lpwhr->lpszPath[nLen-1] == '\n')))
|
||||
lpwhr->lpszPath[--nLen]='\0';
|
||||
}
|
||||
if(strncmp(lpwhr->lpszPath, "http://", sizeof("http://") -1) != 0
|
||||
&& lpwhr->lpszPath[0] != '/') /* not an absolute path ?? --> fix it !! */
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue