I am not sure if this is a bug--and if it is, what it is due to--but on OSX at least, connecting an OSCSender to 127.0.0.1 and sending messages (either with send() or sendToIPAddress()) sends the messages to 0.0.0.0 instead of 127.0.0.1. Tested with the OSCSender example of JUCE 4.1.0 as well as the latest git version.
Is this normal behaviour? Does this mean that JUCE is sending OSC messages on all IPs? I need messages to only be sent to the local IP. I'm checking the network status through XCode's network debug interface, if this makes any difference. By constrast, using liblo (in my own project) sends messages directly to 127.0.0.1.
This is not actually an OSC issue, but an issue with the underlying DatagramSocket.
We'll take a look.
I’ve been looking through the recent changes on git, but could not find something directly related to this issue… was it fixed in a recent update? Updating to the latest version seems to be kind of a pain (bunch of unusual xcode errors), so I thought I’d ask first.
What are the “unusual Xcode errors” you are getting?
I had errors related to juce modules that were not included–totally irrelevant to this issue. I fixed all of those, and the main issue remains: When sending osc messages to 127.0.0.1, they are send to 0.0.0.0. This is a serious issue for us, because we only want to send messages to the local machine, not to all IP addresses.
Just did some new tests to confirm. This is what xcode reports when sending OSC messages with liblo:
Sending the exact same messages with juce gives this:
Why do I get specific local and remote addresses with liblo but 0.0.0.0 with juce?