Skip to content

Commit

Permalink
Restyled by clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
restyled-commits authored and lpbeliveau-silabs committed Oct 13, 2023
1 parent 1722780 commit 3c90a22
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions src/app/clusters/scenes-server/scenes-server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,10 @@ CHIP_ERROR ScenesServer::Init()
if (EMBER_ZCL_STATUS_SUCCESS == status)
{
// According to spec, bit 7 MUST match feature bit 0 (SceneNames)
BitMask<NameSupportBitmap> nameSupport =
(featureMap & to_underlying(Feature::kSceneNames)) ? BitMask<NameSupportBitmap>(NameSupportBitmap::kSceneNames) : BitMask<NameSupportBitmap>();
status = Attributes::NameSupport::Set(endpoint, nameSupport);
BitMask<NameSupportBitmap> nameSupport = (featureMap & to_underlying(Feature::kSceneNames))
? BitMask<NameSupportBitmap>(NameSupportBitmap::kSceneNames)
: BitMask<NameSupportBitmap>();
status = Attributes::NameSupport::Set(endpoint, nameSupport);
if (EMBER_ZCL_STATUS_SUCCESS != status)
{
ChipLogDetail(Zcl, "ERR: setting NameSupport on Endpoint %hu Status: %x", endpoint, status);
Expand All @@ -138,7 +139,7 @@ CHIP_ERROR ScenesServer::Init()
status = Attributes::FeatureMap::Set(endpoint, featureMap);
if (EMBER_ZCL_STATUS_SUCCESS != status)
{
ChipLogDetail(Zcl, "ERR: getting the scenes FeatureMap on Endpoint %hu Status: %x", endpoint, status);
ChipLogDetail(Zcl, "ERR: setting the scenes FeatureMap on Endpoint %hu Status: %x", endpoint, status);
}

status = Attributes::LastConfiguredBy::SetNull(endpoint);
Expand Down Expand Up @@ -206,7 +207,8 @@ void AddSceneParse(CommandHandlerInterface::HandlerContext & ctx, const CommandD

auto fieldSetIter = req.extensionFieldSets.begin();

uint8_t EFSCount = 0;
uint8_t EFSCount = 0;

uint32_t featureMap = 0;
ReturnOnFailure(AddResponseOnError(ctx, response, Attributes::FeatureMap::Get(ctx.mRequestPath.mEndpointId, &featureMap)));

Expand Down Expand Up @@ -389,7 +391,6 @@ CHIP_ERROR StoreSceneParse(const FabricIndex & fabricIdx, const EndpointId & end
}
else
{

uint32_t featureMap = 0;
ReturnErrorOnFailure(
StatusIB(ToInteractionModelStatus(Attributes::FeatureMap::Get(endpointID, &featureMap))).ToChipError());
Expand Down

0 comments on commit 3c90a22

Please sign in to comment.