ISO15765: Bugfix, LIN config influenced CAN
This patch fixes the update_config routine, which turned off the CAN config, when LIN diagnostic frame parsing is deactivated. Closes #17639
This commit is contained in:
parent
f9d3b9d51a
commit
a534b7aed0
|
@ -693,24 +693,21 @@ dissect_iso15765_flexray(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, vo
|
||||||
static void
|
static void
|
||||||
update_config(void)
|
update_config(void)
|
||||||
{
|
{
|
||||||
if (iso15765_handle_lin == NULL) {
|
if (iso15765_handle_lin != NULL) {
|
||||||
return;
|
dissector_delete_all("lin.frame_id", iso15765_handle_lin);
|
||||||
|
if (register_lin_diag_frames) {
|
||||||
|
/* LIN specification states that 0x3c and 0x3d are for diagnostics */
|
||||||
|
dissector_add_uint("lin.frame_id", LIN_DIAG_MASTER_REQUEST_FRAME, iso15765_handle_lin);
|
||||||
|
dissector_add_uint("lin.frame_id", LIN_DIAG_SLAVE_RESPONSE_FRAME, iso15765_handle_lin);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dissector_delete_all("lin.frame_id", iso15765_handle_lin);
|
if (iso15765_handle_can != NULL) {
|
||||||
if (register_lin_diag_frames) {
|
dissector_delete_all("can.id", iso15765_handle_can);
|
||||||
/* LIN specification states that 0x3c and 0x3d are for diagnostics */
|
dissector_delete_all("can.extended_id", iso15765_handle_can);
|
||||||
dissector_add_uint("lin.frame_id", LIN_DIAG_MASTER_REQUEST_FRAME, iso15765_handle_lin);
|
|
||||||
dissector_add_uint("lin.frame_id", LIN_DIAG_SLAVE_RESPONSE_FRAME, iso15765_handle_lin);
|
|
||||||
}
|
|
||||||
|
|
||||||
dissector_delete_all("can.id", iso15765_handle_can);
|
|
||||||
dissector_delete_all("can.extended_id", iso15765_handle_can);
|
|
||||||
if (register_lin_diag_frames) {
|
|
||||||
dissector_add_uint_range("can.id", configured_can_ids, iso15765_handle_can);
|
dissector_add_uint_range("can.id", configured_can_ids, iso15765_handle_can);
|
||||||
dissector_add_uint_range("can.extended_id", configured_ext_can_ids, iso15765_handle_can);
|
dissector_add_uint_range("can.extended_id", configured_ext_can_ids, iso15765_handle_can);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
Loading…
Reference in New Issue