mirror of
https://github.com/espressif/esp-mqtt.git
synced 2025-07-31 19:25:14 +02:00
Fix C++ build, add extern "C" to header file. (#49)
This commit is contained in:
@@ -14,6 +14,10 @@
|
||||
|
||||
#include "mqtt_config.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
typedef struct esp_mqtt_client* esp_mqtt_client_handle_t;
|
||||
|
||||
typedef enum {
|
||||
@@ -85,4 +89,8 @@ esp_err_t esp_mqtt_client_unsubscribe(esp_mqtt_client_handle_t client, const cha
|
||||
int esp_mqtt_client_publish(esp_mqtt_client_handle_t client, const char *topic, const char *data, int len, int qos, int retain);
|
||||
esp_err_t esp_mqtt_client_destroy(esp_mqtt_client_handle_t client);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif //__cplusplus
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user