[Gambas-user] not able to send UDP datagram on local host

T Lee Davidson t.lee.davidson at gmail.com
Thu Sep 3 19:58:31 CEST 2020


On 9/2/20 5:34 PM, T Lee Davidson wrote:
> On 9/2/20 5:09 PM, Benoît Minisini wrote:
>> I just set the TargetPort property of UdpCmd to 50000, and everything works as expected (I see "Test-1" in the left textarea).
>>
>> If you don't set the Broadcast property, then you have to set the TargetHost to 127.0.0.1.
> 
> No matter how I've tried to configure the sockets, I keep getting a SegFault:
> QSocketNotifier: Invalid socket 14 and type 'Read', disabling...
> 

Correction: Whether or not the Broadcast property is set, if TargetHost is blank I get the SegFault.

If I set TargetHost to 127.255.255.255, or to 0, it works as expected. Should the IDE prevent TargetHost and TargetPort from 
being blank if Broadcast is set?

By the way, if I put any value in the UdpSocket's Group property, at Run I get:
Unknown symbol 'Name' in class 'UdpSocket'


-- 
Lee


More information about the User mailing list