[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [lwip-users] WS_send data pointer
From: |
address@hidden |
Subject: |
Re: [lwip-users] WS_send data pointer |
Date: |
Tue, 4 May 2021 15:51:23 +0200 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.10.0 |
Am 04.05.2021 um 10:10 schrieb Jonathan Vervaeke:
> Hello,
> Using LwIP stack, shipped with the NXP SDK on a imxrt1062 SoM.
> in httpsrv_ws_api.c, the WS_send function is defined, which passes a
> datapointer (from the context parameter), via a message system
> (sys_mbox_post), to the api_queue.
>
> I wonder how to guarantee that the pointer is still valid after sending
> a message via WS_send. Now, my data is placed on the stack just before
> calling WS_send, but since the function returns (possibly) before using
> the data, I'm very unsure on how to implement this.
>
> Do you have feedback on this issue?
My only feedback is that this whole file "httpsrv_ws_api.c" is not part
of lwIP, but probably part of what your vendor has added.
Regards,
Simon