microsoft/cpprestsdk

web_proxy doesn't work when using port numbers in address

オープン

#57 opened on 2016/01/18

 (1 件のコメント) (0 件のリアクション) (0 人の担当者)C++ (1,670 件のフォーク)batch import
bughelp wanted

Repository metrics

Stars
 (7,596 個のスター)
PR merge metrics
 (PR metrics pending)

説明

I tested this with v2.7.0 and v2.1.0 (with vc12 and vc14 on win10 and server2012), on about 20 proxy machines I know are good. I though it had worked with some old cpprest version but probably not. (I know the proxies are fine as I use them fine through libcurl).

Minimal example: I get the error "web::uri_exception: provided uri is invalid":

#include <cpprest/http_client.h>
int main() {
    try {
        //web::http::client::web_proxy wp2(L"123.123.123.123"); //OK
        web::http::client::web_proxy wp2(L"123.123.123.123:1234"); //Error
        std::cout << "OK" << std::endl;
    }
    catch (const std::exception& exc) {
        std::cerr << exc.what() << std::endl;
    }
}

コントリビューターガイド