mirror of
https://github.com/eclipse/paho.mqtt-sn.embedded-c.git
synced 2025-12-13 07:26:52 +01:00
@@ -116,7 +116,7 @@ typedef struct
|
||||
unsigned char version; /**< MQTT version number */
|
||||
} Connect;
|
||||
|
||||
#define MQTTPacket_Connect_Initializer {{0}, 0, nullptr, nullptr, nullptr, nullptr, 0, 0}
|
||||
#define MQTTPacket_Connect_Initializer {{0}, {0}, nullptr, nullptr, nullptr, nullptr, 0, 0}
|
||||
#define MQTTPacket_willOptions_initializer { {'M', 'Q', 'T', 'W'}, 0, {NULL, {0, NULL}}, {NULL, {0, NULL}}, 0, 0 }
|
||||
#define MQTTPacket_connectData_initializer { {'M', 'Q', 'T', 'C'}, 0, 4, {NULL, {0, NULL}}, 60, 1, 0, \
|
||||
MQTTPacket_willOptions_initializer, {NULL, {0, NULL}}, {NULL, {0, NULL}} }
|
||||
|
||||
@@ -39,7 +39,6 @@ public:
|
||||
private:
|
||||
void sendStoredPublish(Client* client);
|
||||
|
||||
char _pbuf[MQTTSNGW_MAX_PACKET_SIZE * 3];
|
||||
Gateway* _gateway;
|
||||
};
|
||||
|
||||
|
||||
@@ -145,7 +145,11 @@ bool TCPStack::accept(TCPStack& new_socket)
|
||||
|
||||
int TCPStack::send(const uint8_t* buf, int length)
|
||||
{
|
||||
#ifdef __APPLE__
|
||||
return ::send(_sockfd, buf, length, SO_NOSIGPIPE);
|
||||
#else
|
||||
return ::send(_sockfd, buf, length, MSG_NOSIGNAL);
|
||||
#endif
|
||||
}
|
||||
|
||||
int TCPStack::recv(uint8_t* buf, int len)
|
||||
|
||||
Reference in New Issue
Block a user