Boost logo

Boost Users :

Subject: Re: [Boost-users] Incorrect parameters problem
From: Michael Caisse (boost_at_[hidden])
Date: 2009-10-30 01:31:00


Mathew Benson wrote:
> Thanks. Now I feel dumb.

Don't ... this question comes up on IRC about once a week.

The problem is that the most likely mistake is actually a valid
overload. But instead of assigning the port you are setting
some flags. It would be nice if the flags were not an int.

michael

>
> Sent from my iPhone
>
> On Oct 29, 2009, at 6:10 PM, Michael Caisse
> <boost_at_[hidden]> wrote:
>
>> Mathew Benson wrote:
>>> My project was compiling and executing, but I get an error now. I'm
>>> not sitting at my desk right now, but I think it said "Incorrect
>>> parameters" when I examine the error. Here's the offending code:
>>> boost::asio::io_service io_service;
>>> using boost::asio::ip::udp;
>>> udp::socket s(io_service, udp::endpoint(udp::v4(),
>>> 0)); udp::resolver resolver(io_service);
>>> udp::resolver::query query(udp::v4(), "127.0.0.1", 606);
>>>
>>
>> udp::resolver::query query(udp::v4(), "127.0.0.1", "606");
>>
>>
>> Regards -
>> michael
>>
>> --
>>
>> ----------------------------------
>> Michael Caisse
>> Object Modeling Designs
>> www.objectmodelingdesigns.com
>>
>>


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