[Tinyos-devel] Bug in TossimActiveMessageC
Lumir Honus
foldus at gmail.com
Thu Jan 22 06:58:36 PST 2009
Thank you very much for explanation.
On Thu, Jan 22, 2009 at 5:16 AM, Philip Levis <pal at cs.stanford.edu> wrote:
>
> On Jan 21, 2009, at 8:02 PM, Lumir Honus wrote:
>
>> event message_t*
>> ExtReceive.receive[am_id_t id](message_t* msg, void* payload, uint8_t len)
>> {
>> am_id_t type = call AMPacket.type(msg);
>> call TrafficDebug.logReceived(type,msg,len);
>> signal Receive.receive[type](msg, payload, len);
>> return msg;
>> }
>
> This is a bug. If the receive handler buffer swaps, then you ignore the
> pointer passed back. In this case, the higher layer uses the message buffer
> (e.g., to send a packet, and puts it in a queue) but the underlying radio
> stack is using it for reception.
>
> Phil
>
--
---------------------------------------------------------------------
S pozdravem
Lumir Honus
More information about the Tinyos-devel
mailing list