diff --git a/source/module.c b/source/module.c index 8ab6b08b3..93e2a7c0f 100644 --- a/source/module.c +++ b/source/module.c @@ -402,7 +402,8 @@ static void s_error_map_init(void) { {PyExc_ValueError, AWS_ERROR_INVALID_ARGUMENT}, {PyExc_FileNotFoundError, AWS_ERROR_FILE_INVALID_PATH}, {PyExc_BlockingIOError, AWS_IO_READ_WOULD_BLOCK}, - {PyExc_BrokenPipeError, AWS_IO_BROKEN_PIPE}}; + {PyExc_BrokenPipeError, AWS_IO_BROKEN_PIPE}, + }; if (aws_hash_table_init( &s_py_to_aws_error_map, diff --git a/source/mqtt5_client.c b/source/mqtt5_client.c index 625580e1a..d6f0f3ce0 100644 --- a/source/mqtt5_client.c +++ b/source/mqtt5_client.c @@ -271,9 +271,7 @@ static void s_on_publish_received(const struct aws_mqtt5_packet_publish_view *pu /* i */ (int)(publish_packet->payload_format ? *publish_packet->payload_format : 0), /* O */ publish_packet->message_expiry_interval_seconds ? Py_True : Py_False, /* I */ - (unsigned int)(publish_packet->message_expiry_interval_seconds - ? *publish_packet->message_expiry_interval_seconds - : 0), + (unsigned int)(publish_packet->message_expiry_interval_seconds ? *publish_packet->message_expiry_interval_seconds : 0), /* O */ publish_packet->topic_alias ? Py_True : Py_False, /* H */ (unsigned short)(publish_packet->topic_alias ? *publish_packet->topic_alias : 0), /* s */ publish_packet->response_topic ? publish_packet->response_topic->ptr : NULL, @@ -541,9 +539,7 @@ static void s_lifecycle_event_disconnection( /* i */ (int)(disconnect ? disconnect->reason_code : 0), /* O */ (disconnect && disconnect->session_expiry_interval_seconds) ? Py_True : Py_False, /* I */ - (unsigned int)((disconnect && disconnect->session_expiry_interval_seconds) - ? *disconnect->session_expiry_interval_seconds - : 0), + (unsigned int)((disconnect && disconnect->session_expiry_interval_seconds) ? *disconnect->session_expiry_interval_seconds : 0), /* s */ (disconnect && disconnect->reason_string) ? disconnect->reason_string->ptr : NULL, /* # */ (disconnect && disconnect->reason_string) ? disconnect->reason_string->len : 0, /* O */ user_property_count > 0 ? user_properties_list : Py_None,