MCPcopy Create free account
hub / github.com/Serial-Studio/Serial-Studio / portIsValid

Function portIsValid

app/src/API/Handlers/MqttHandler.cpp:32–35  ·  view source on GitHub ↗

* @brief Returns true when port is within the valid [1, 65535] TCP range. */

Source from the content-addressed store, hash-verified

30 * @brief Returns true when port is within the valid [1, 65535] TCP range.
31 */
32[[nodiscard]] static bool portIsValid(int port)
33{
34 return port >= 1 && port <= 65535;
35}
36
37/**
38 * @brief Validates that an integer falls within [0, modeCount).

Callers 2

applyPublisherEndpointFunction · 0.85
applySubscriberEndpointFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected