BUG: uninitialized pointer in httpsrv_plugin_task()

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

BUG: uninitialized pointer in httpsrv_plugin_task()

1,071件の閲覧回数
PetrK
Contributor II

Hello,

I've played a little with KSDK MQX httpsrv_demo application focused to websocket part as it is my primary interest and found the application starts crashing randomly with corrupted memory. So I've tracked it down to the function httpsrv_plugin_task() in tcpip/rtcs/source/apps/httpsrv_task.c where unitialized pointer pl_context is accessed (tested to NULL). The bug is simple fixed by initializing the pointer to NULL.

Hopefully this helps somebody :smileyhappy:

Petr

PS: The websocket implementation is quite good as it passed almost all tests in AutobahnTestSuite.

ラベル(1)
0 件の賞賛
返信
1 返信

907件の閲覧回数
RadekS
NXP Employee
NXP Employee

Thank you for your bug report.

It is known issue and it was already fixed at development branch – so it will be fixed in next version of KSDK.

Function httpsrv_plugin_task() in httpsrv_task.c file contains additional two lines:

pl_context = NULL;

pl_callbacks = NULL;

just below line “server->plugin_tid = _task_get_id();”


Have a great day,
RadekS

0 件の賞賛
返信