修正解密流量转发中部分回调函数没有正确传线程号,导致线程竞争访问的问题。
This commit is contained in:
@@ -635,7 +635,7 @@ enum tfe_stream_action traffic_mirror_on_data_cb(const struct tfe_stream * strea
|
|||||||
enum tfe_conn_dir dir, const unsigned char * data, size_t len, void ** pme)
|
enum tfe_conn_dir dir, const unsigned char * data, size_t len, void ** pme)
|
||||||
{
|
{
|
||||||
struct traffic_mirror_me * me = (struct traffic_mirror_me *)(*pme);
|
struct traffic_mirror_me * me = (struct traffic_mirror_me *)(*pme);
|
||||||
traffic_mirror_rebuild_data(me->rebuild_ctx, 0, (const char *) data, (size_t) len, dir);
|
traffic_mirror_rebuild_data(me->rebuild_ctx, thread_id, (const char *) data, (size_t) len, dir);
|
||||||
return ACTION_FORWARD_DATA;
|
return ACTION_FORWARD_DATA;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -643,7 +643,7 @@ void traffic_mirror_on_close_cb(const struct tfe_stream * stream, unsigned int t
|
|||||||
enum tfe_stream_close_reason reason, void ** pme)
|
enum tfe_stream_close_reason reason, void ** pme)
|
||||||
{
|
{
|
||||||
struct traffic_mirror_me * me = (struct traffic_mirror_me *)(*pme);
|
struct traffic_mirror_me * me = (struct traffic_mirror_me *)(*pme);
|
||||||
traffic_mirror_rebuild_farewell(me->rebuild_ctx, 0);
|
traffic_mirror_rebuild_farewell(me->rebuild_ctx, thread_id);
|
||||||
traffic_mirror_rebuild_destroy(me->rebuild_ctx);
|
traffic_mirror_rebuild_destroy(me->rebuild_ctx);
|
||||||
profile_table_ex_data_free(me->profile_ex_data);
|
profile_table_ex_data_free(me->profile_ex_data);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user