shell: telnet: Make sure the delayed work becomes idle after canceling
Replace k_work_cancel_delayable() with k_work_cancel_delayable_sync() to make sure that the submitted work becomes idle before accessing sensitive data. Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
This commit is contained in:
parent
501c7d17b0
commit
1a69317eea
2 changed files with 9 additions and 4 deletions
|
@ -46,6 +46,7 @@ struct shell_telnet {
|
|||
* to send the shell prompt for instance.
|
||||
*/
|
||||
struct k_work_delayable send_work;
|
||||
struct k_work_sync work_sync;
|
||||
|
||||
/** If set, no output is sent to the TELNET client. */
|
||||
bool output_lock;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue