Skip to content

Commit

Permalink
Fix Subscriptions capacity option type cast
Browse files Browse the repository at this point in the history
  • Loading branch information
wqx6 committed Jan 9, 2024
1 parent 2e1ba11 commit f260377
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/platform/linux/Options.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ bool HandleOption(const char * aProgram, OptionSet * aOptions, int aIdentifier,
#endif
#if CONFIG_BUILD_FOR_HOST_UNIT_TEST
case kDeviceOption_SubscriptionCapacity:
LinuxDeviceOptions::GetInstance().subscriptionCapacity = static_cast<size_t>(atoi(aValue));
LinuxDeviceOptions::GetInstance().subscriptionCapacity = static_cast<int32_t>(atoi(aValue));
break;
#endif
default:
Expand Down
2 changes: 1 addition & 1 deletion examples/platform/linux/Options.h
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ struct LinuxDeviceOptions
uint16_t rpcServerPort = 33000;
#endif
#if CONFIG_BUILD_FOR_HOST_UNIT_TEST
size_t subscriptionCapacity = CHIP_IM_MAX_NUM_SUBSCRIPTIONS;
int32_t subscriptionCapacity = CHIP_IM_MAX_NUM_SUBSCRIPTIONS;
#endif
static LinuxDeviceOptions & GetInstance();
};
Expand Down

0 comments on commit f260377

Please sign in to comment.