Commit 7aea2d52 authored by Kamil Dudka's avatar Kamil Dudka
Browse files

rtsp: avoid SIGSEGV on malformed header

parent f3e3f5f1
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -706,10 +706,10 @@ CURLcode Curl_rtsp_parseheader(struct connectdata *conn,

    /* Find the first non-space letter */
    start = header + 9;
    while(start && ISSPACE(*start))
    while(*start && ISSPACE(*start))
      start++;

    if(!start) {
    if(!*start) {
      failf(data, "Got a blank Session ID");
    }
    else if(data->set.str[STRING_RTSP_SESSION_ID]) {