From 985fbde26fe79e3638066b2a9136040cf275e0b8 Mon Sep 17 00:00:00 2001 From: Feng Lee Date: Sun, 14 Jun 2015 08:24:17 +0800 Subject: [PATCH] fix issue #174 - add 'from' field to mqtt_message record --- apps/emqtt/include/emqtt.hrl | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/apps/emqtt/include/emqtt.hrl b/apps/emqtt/include/emqtt.hrl index bb17eef64..49a19cf62 100644 --- a/apps/emqtt/include/emqtt.hrl +++ b/apps/emqtt/include/emqtt.hrl @@ -56,17 +56,12 @@ -type mqtt_msgid() :: undefined | 1..16#ffff. -record(mqtt_message, { - %% topic is first for message may be retained - topic :: binary(), - %% clientid from - from :: binary() | atom(), - %% sender pid ?? - sender :: pid(), + topic :: binary(), %% topic published to + from :: mqtt_clientid() | atom(), %% from clientid qos = ?QOS_0 :: mqtt_qos(), retain = false :: boolean(), dup = false :: boolean(), - %% $SYS message flag - sys = false :: boolean(), + sys = false :: boolean(), %% $SYS flag msgid :: mqtt_msgid(), payload :: binary() }).