Commit 9555aa7a authored by phil's avatar phil
Browse files

sdp parse accepts trailing spaces on first line (v=0)

parent 1e64f6ad
......@@ -1391,17 +1391,17 @@ u32_t aes67_sdp_fromstr(struct aes67_sdp *sdp, u8_t *str, u32_t len, void *user_
u32_t pos = 3;
// abort if no line termination
if (!IS_CRNL(str[pos])){
// skip to \n
while (pos < len && str[pos] != NL){
pos++;
}
// sanity check not beyond given string
if (pos >= len){
return AES67_SDP_ERROR;
}
// move position beyond newline
pos++;
// if only NL skip (ie 2 chars for newline CRNL)
if (IS_NL(str[pos])) {
pos++;
}
// reset
aes67_sdp_init(sdp);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment