Skip to content
Snippets Groups Projects
Commit b3ce3cba authored by Lorenz Meier's avatar Lorenz Meier Committed by Daniel Agar
Browse files

Simple mixer: Remove incorrect pre-parser and replace with fixed central implementation

parent dd05ff51
No related branches found
No related tags found
No related merge requests found
......@@ -161,6 +161,11 @@ SimpleMixer::from_text(Mixer::ControlCallback control_cb, uintptr_t cb_handle, c
int used;
const char *end = buf + buflen;
/* enforce that the mixer ends with a new line */
if (!string_well_formed(buf, buflen)) {
return nullptr;
}
/* get the base info for the mixer */
if (sscanf(buf, "M: %u%n", &inputs, &used) != 1) {
debug("simple parse failed on '%s'", buf);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment