Skip to content

Commit

Permalink
Fix default protocol variables.
Browse files Browse the repository at this point in the history
  • Loading branch information
abeltrano committed Mar 25, 2024
1 parent 874efa8 commit 6a91f67
Showing 1 changed file with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,20 @@

namespace Microsoft::Net::Remote::Protocol
{
static constexpr uint32_t NetRemotePortDefault = 5047;
static constexpr std::string_view NetRemoteAddressHttpDefault = "localhost:5047";

/**
* @brief Static NetRemote protocol information.
*/
struct NetRemoteProtocol
{
#define IP_DEFAULT "localhost"
#define PORT_DEFAULT 5047
#define PORT_SEPARATOR ""
#define PORT_SEPARATOR ":"
#define xstr(s) str(s)
#define str(s) #s

static constexpr uint32_t PortDefault{ 5047 };
static constexpr std::string_view PortSeparator{ ":" };
static constexpr std::string_view IpDefault{ "localhost" };
static constexpr uint32_t PortDefault{ PORT_DEFAULT };
static constexpr std::string_view PortSeparator{ PORT_SEPARATOR };
static constexpr std::string_view IpDefault{ IP_DEFAULT };
static constexpr std::string_view AddressDefault{ IP_DEFAULT PORT_SEPARATOR xstr(PORT_DEFAULT) };

#undef IP_DEFAULT
Expand Down

0 comments on commit 6a91f67

Please sign in to comment.