-5

Working on a driver development, I'm try to publish my data with MQtt in C its running but giving me Error code -1 (MQTTCLIENT_FAILURE you can see in that picture )

I installed ActiveMQ broker in my system and test in MQTTbox that its working properly So Im not getting my problem Thank you

I'm using that code

hardillb
  • 54,545
  • 11
  • 67
  • 105
  • Do not post pictures of code or error messages, it makes them totally un searchable – hardillb May 11 '18 at 13:45
  • _I'm try to publish my data with MQtt in C_ So, what is the tag [tag:c++] good for? (Please, prevent tag spamming. That's disliked and good for down-votes only.) – Scheff's Cat May 11 '18 at 14:16

1 Answers1

0

AS you can see on https://www.ibm.com/support/knowledgecenter/en/SSFKSJ_7.5.0/com.ibm.mq.javadoc.doc/WMQMQxrCClasses/_m_q_t_t_client_8h.html#af33a6d6c0e8a6a747bf39638e0bba36b #define MQTTCLIENT_FAILURE -1 Return code: A generic error code indicating the failure of an MQTT client operation."

You should set break point in every occurence of "MQTTClient_publish" in "MQTTClient_publish" function to determine exacly reason why you can not publish. There is only 4 occurences, so it should go easy.