Skip to content

Commit ca06334

Browse files
committed
clearing SubscriptionList entries in shadowActionAcks after subscription failure
Fixes #62
1 parent 9b84c7b commit ca06334

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/aws_iot_shadow_records.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,8 @@ IoT_Error_t subscribeToShadowActionAcks(const char *pThingName, ShadowActions_t
369369
if(clearBothEntriesFromList) {
370370
if(indexAcceptedSubList >= 0) {
371371
SubscriptionList[indexAcceptedSubList].isFree = true;
372-
} else if(indexRejectedSubList >= 0) {
372+
}
373+
if(indexRejectedSubList >= 0) {
373374
SubscriptionList[indexRejectedSubList].isFree = true;
374375
}
375376
if(SubscriptionList[indexAcceptedSubList].count == 1) {

0 commit comments

Comments
 (0)