mqttClient Service Connect error: mqtt_Connect() Socket error?

I’m developing a SW to connect with mosquitto broker. I started from the source code in apps/platformservices of Legato environment.
I can right build the project, create the session, but I have problem when I have to connect to the broker (both if i give mosquitto or AirVantage adress broker):
I’m trying to connect without user and password (I’m beginning!) and this is the result:

Obviously I connected my mangOH green to internet thought both WiFi and Sim and I can righly ping google, so it is not a connection trouble. Mosquitto is running on my VM:
Can someone help me to understand the cause of this problem? Here is the code I’m working on…maqqClientServicee.txt (36.7 KB)
Which could be the problem?

Hi ga.imparato,

These are the mqttClient instructions for Legato. Please refer to them.