Skip to content

Commit

Permalink
kMaxCommisisonableServiceNameSize -> kMaxCommissionableServiceNameSiz…
Browse files Browse the repository at this point in the history
…e and kMaxCommisisonerServiceNameSize -> kMaxCommissionerServiceNameSize
  • Loading branch information
vivien-apple committed Dec 1, 2021
1 parent 02bd2c7 commit 66373ea
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/lib/dnssd/Discovery_ImplPlatform.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -534,7 +534,7 @@ void DiscoveryImplPlatform::HandleNodeResolve(void * context, DnssdService * res
CHIP_ERROR DiscoveryImplPlatform::FindCommissionableNodes(DiscoveryFilter filter)
{
ReturnErrorOnFailure(InitImpl());
char serviceName[kMaxCommisisonableServiceNameSize];
char serviceName[kMaxCommissionableServiceNameSize];
ReturnErrorOnFailure(MakeServiceTypeName(serviceName, sizeof(serviceName), filter, DiscoveryType::kCommissionableNode));

return ChipDnssdBrowse(serviceName, DnssdServiceProtocol::kDnssdProtocolUdp, Inet::IPAddressType::kAny,
Expand All @@ -544,7 +544,7 @@ CHIP_ERROR DiscoveryImplPlatform::FindCommissionableNodes(DiscoveryFilter filter
CHIP_ERROR DiscoveryImplPlatform::FindCommissioners(DiscoveryFilter filter)
{
ReturnErrorOnFailure(InitImpl());
char serviceName[kMaxCommisisonerServiceNameSize];
char serviceName[kMaxCommissionerServiceNameSize];
ReturnErrorOnFailure(MakeServiceTypeName(serviceName, sizeof(serviceName), filter, DiscoveryType::kCommissionerNode));

return ChipDnssdBrowse(serviceName, DnssdServiceProtocol::kDnssdProtocolUdp, Inet::IPAddressType::kAny,
Expand Down
4 changes: 2 additions & 2 deletions src/lib/dnssd/ServiceNaming.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@ constexpr char kCommissionProtocol[] = "_udp";
constexpr char kLocalDomain[] = "local";

// each includes space for a null terminator, which becomes a . when the names are appended.
constexpr size_t kMaxCommisisonableServiceNameSize =
constexpr size_t kMaxCommissionableServiceNameSize =
Common::kSubTypeMaxLength + 1 + sizeof(kSubtypeServiceNamePart) + sizeof(kCommissionableServiceName);

// each includes space for a null terminator, which becomes a . when the names are appended.
constexpr size_t kMaxCommisisonerServiceNameSize =
constexpr size_t kMaxCommissionerServiceNameSize =
Common::kSubTypeMaxLength + 1 + sizeof(kSubtypeServiceNamePart) + sizeof(kCommissionerServiceName);

// + 1 for nullchar on prefix.
Expand Down

0 comments on commit 66373ea

Please sign in to comment.