mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 18:21:04 +00:00
client: guard against invalid paths
This commit is contained in:
parent
68804ff984
commit
171e89c63a
1 changed files with 2 additions and 2 deletions
|
@ -721,8 +721,8 @@ handle_setup_request (GstRTSPClient * client, GstRTSPUrl * uri,
|
|||
* always /stream=%d so we need to strip that off
|
||||
* parse the stream we need to configure, look for the stream in the abspath
|
||||
* first and then in the query. */
|
||||
if (!(pos = strstr (uri->abspath, "/stream="))) {
|
||||
if (!(pos = strstr (uri->query, "/stream=")))
|
||||
if (uri->abspath == NULL || !(pos = strstr (uri->abspath, "/stream="))) {
|
||||
if (uri->query == NULL || !(pos = strstr (uri->query, "/stream=")))
|
||||
goto bad_request;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue