Skip to content

Commit

Permalink
Sync point
Browse files Browse the repository at this point in the history
  • Loading branch information
bretambrose committed Jan 26, 2024
1 parent a54824a commit abbcdc1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ enum aws_protocol_adapter_subscription_event_type {
struct aws_protocol_adapter_subscription_event {
struct aws_byte_cursor topic_filter;
enum aws_protocol_adapter_subscription_event_type event_type;
int error_code;
};

/*
Expand Down
2 changes: 2 additions & 0 deletions source/request-response/protocol_adapter.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,7 @@ static void s_protocol_adapter_5_subscribe_completion(
struct aws_protocol_adapter_subscription_event subscribe_event = {
.topic_filter = aws_byte_cursor_from_buf(&subscribe_data->topic_filter),
.event_type = success ? AWS_PASET_SUBSCRIBE_SUCCESS : AWS_PASET_SUBSCRIBE_FAILURE,
.error_code = error_code,
};

(*adapter->config.subscription_event_callback)(&subscribe_event, adapter->config.user_data);
Expand Down Expand Up @@ -176,6 +177,7 @@ static void s_protocol_adapter_5_unsubscribe_completion(
struct aws_protocol_adapter_subscription_event unsubscribe_event = {
.topic_filter = aws_byte_cursor_from_buf(&unsubscribe_data->topic_filter),
.event_type = success ? AWS_PASET_UNSUBSCRIBE_SUCCESS : AWS_PASET_UNSUBSCRIBE_FAILURE,
.error_code = error_code,
};

(*adapter->config.subscription_event_callback)(&unsubscribe_event, adapter->config.user_data);
Expand Down

0 comments on commit abbcdc1

Please sign in to comment.