Quantcast
Channel: WE MOVED to github.com/microsoft/cpprestsdk. This site is not monitored!
Viewing all articles
Browse latest Browse all 4845

Created Unassigned: int web::uri::port() const always returns 0 [281]

$
0
0
From doc, web::uri::port is supposed to return either the port number or -1.
> int web::uri::port ( ) const
>inline
>Get the port component of the URI. Returns -1 if no port is specified.

>Returns
>The URI port as an integer.

However in practice, for instance:

```
web::uri wAddress(L"http://*/something:8080");
int wPortNumber = wAddress.port(); // <-- will return 0!
```
It returns 0 no matter what. Am I the only one experiencing this issue?

Viewing all articles
Browse latest Browse all 4845

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>