Boost logo

Boost Users :

Subject: Re: [Boost-users] Server application won't bind to ports on IP address other than my internal ones
From: Osman Zakir (osmanzakir90_at_[hidden])
Date: 2019-01-10 11:30:36


The problem is mostly likely in ASIO, Beast, or my extension networking code. The dependencies are for Google Maps, currency conversion, JSON data and HTML templates. There's nothing there to affect server app not being able to bind to ports, is there? The problem is only about binding to ports.

I get an error that's triggered from this piece of code (it's on lines 467 to 474 in the C++ code, including the one-line comment above that first line shown here): [It's an error from bind() which should be in Asio, but I don't know where to look for the definition.]

        acceptor_.bind(endpoint, ec);
        if (ec)
        {
            std::cerr << "Lines 471 and 472:\n";
            fail(ec, "bind");
            return;

}

________________________________
From: degski <degski_at_[hidden]>
Sent: Thursday, January 10, 2019 4:15 PM
To: boost-users_at_[hidden]
Cc: Osman Zakir
Subject: Re: [Boost-users] Server application won't bind to ports on IP address other than my internal ones

On Thu, 10 Jan 2019 at 12:15, Osman Zakir via Boost-users <boost-users_at_[hidden]<mailto:boost-users_at_[hidden]>> wrote:
If you guys haven't already, I'd like to ask you to read my app's source code. Especially the C++ code. And please also actually get the code and try to run it (though for that you'll need Jinja2Cpp and Nlohmann/JSON and also a Google Maps API Key and currencylayer.com<http://currencylayer.com> API access key). I need some help in debugging the networking code. I also opened an issue about this ten days on the Boost.Asio GitHub, the link for which is: https://github.com/boostorg/asio/issues/184 . The link to my app's code on GitHub is there, as well as the links to the Boost.Beast example code that I used (note: I didn't write the networking code myself; I just used the examples given on Beast's GitHub repository and extended it to also handle POST requests).

If there's any info you guys need that I haven't given yet, let me know and I'll give it.

You're kiddin' right?

You are actually asking [some pretty busy] people to [get acquainted with, and] debug your code for you, for free, I presume. Iff you have a minimal example exposing you're problem, maybe some help might come your way, but you're already sighting a gazillion dependencies, the problem could be anywhere [but most probably in your own code, look there, check invariants, assumptions you make and re-read docs pertaining to your dependencies]. You write: "... I just used the examples given on Beast's GitHub repository and extended it to also handle POST requests)", that sounds like a likely candidate [the "just" doesn't sound right in my ear].

degski

--
“If something cannot go on forever, it will stop" - Herbert Stein


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net