Styles
ci / checks (push) Successful in 39m31s

This commit is contained in:
khodowany
2026-09-08 22:07:31 -05:00
parent 6e7db6fd97
commit fa7485d404
28 changed files with 522 additions and 292 deletions
+1 -7
View File
@@ -43,7 +43,6 @@ auto strip_cr(std::string_view line) -> std::string_view {
auto vamp_pico::parse_remote_display_body(std::string_view body, vamp_pico::remote_display_state& state) -> std::bool_t {
auto parsed = vamp_pico::remote_display_state{};
auto saw_version = std::bool_t{};
auto cursor = std::size_t{};
while (cursor <= body.size()) {
auto line_end = body.find('\n', cursor);
@@ -53,9 +52,7 @@ auto vamp_pico::parse_remote_display_body(std::string_view body, vamp_pico::remo
if (equals != std::string_view::npos) {
auto key = line.substr(0U, equals);
auto value = line.substr(equals + 1U);
if (key == "version") {
saw_version = true;
} else if (key == "active") {
if (key == "active") {
parsed.active = value == "1";
} else if (key == "title") {
copy_value(value, parsed.title, sizeof(parsed.title));
@@ -78,9 +75,6 @@ auto vamp_pico::parse_remote_display_body(std::string_view body, vamp_pico::remo
}
cursor = line_end + 1U;
}
if (!saw_version) {
return false;
}
state = parsed;
return true;
}