Lines Matching refs:topic
394 char *topic, char *payload, size_t payloadlen)
396 size_t topiclen = strlen(topic);
431 memcpy(&packet[3 + encodedlen], topic, topiclen);
454 static char topic[MAX_TOPIC_LENGTH + 1];
635 /* two bytes topic length */
638 logmsg("Wrong topic length, got %zu expected %zu",
642 memcpy(topic, &buffer[4], topic_len);
643 topic[topic_len] = 0;
645 /* there's a QoS byte (two bits) after the topic */
647 logmsg("SUBSCRIBE to '%s' [%d]", topic, packet_id);
657 if(publish(dump, fd, packet_id, topic, data, datalen)) {
670 publish(dump, fd, packet_id, topic, def, strlen(def));
682 logmsg("Got %zu bytes topic", topiclen);