version 1.1.2.5, 2012/05/01 01:12:16
|
version 1.1.2.6, 2012/05/05 13:10:24
|
Line 53 SUCH DAMAGE.
|
Line 53 SUCH DAMAGE.
|
#ifdef API_SERVER_SIDE |
#ifdef API_SERVER_SIDE |
/* MQTT server structure & hooks */ |
/* MQTT server structure & hooks */ |
|
|
/* MQTT command callback. 1st argument is (mqtt_srv_t*) server handle */ | /* MQTT command callback. 1st argument is (mqtt_srv_t*) server handle, 2nd is ready length */ |
typedef int (*mqtt_cb_t)(void* /*mqtt_srv_t**/, void *); | typedef int (*mqtt_cb_t)(void* /*mqtt_srv_t**/, int, void *); |
typedef struct { |
typedef struct { |
mqtt_cb_t cmds[MQTT_TYPE_MAX]; |
mqtt_cb_t cmds[MQTT_TYPE_MAX]; |
|
|
Line 85 void mqtt_srv_Fini(mqtt_srv_t ** __restrict psrv);
|
Line 85 void mqtt_srv_Fini(mqtt_srv_t ** __restrict psrv);
|
* |
* |
* @srv = Server handle |
* @srv = Server handle |
* @arg = Argument pass to command callback |
* @arg = Argument pass to command callback |
|
* @rlen = Ready bytes to parse |
* return: -1 error or 0 ok |
* return: -1 error or 0 ok |
*/ |
*/ |
int mqtt_srv_Dispatch(mqtt_srv_t * __restrict srv, void *arg); | int mqtt_srv_Dispatch(mqtt_srv_t * __restrict srv, void *arg, int rlen); |
#endif |
#endif |
|
|
/* |
/* |