RaspberrPi project source code
guowenxue
11 hours ago 24345339421493cdacdbaae0248c3928ea9404c2
project/lightd/config.h
@@ -14,6 +14,7 @@
#define  __CONF_H_
#include <stddef.h>
#include "utils.h"
#include "gpio.h"
enum
@@ -75,7 +76,6 @@
} iotd_ctx_t;
/* get iotd_ctx address by mqtt_ctx address */
#define container_of(ptr, type, member) ((type *)((char *)(ptr) - offsetof(type, member)))
#define to_iotd(ctx)   container_of(ctx, iotd_ctx_t, mqtt);
extern int parser_conf(const char *conf_file, iotd_ctx_t *ctx, int debug);