mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-18 15:51:11 +00:00
gstrtspsrc: 551 should not result in an unhandled error
Some cameras (e.g. HikVision DS-2CD2732F-IS) return "551 Option not supported" when a command is sent that is not implemented (e.g. PAUSE). Instead; it should return "501 Not Implemented". This is wrong, as previously, the camera did announce support for PAUSE in the OPTIONS. In this case, handle the 551 as if it was 501 to avoid throwing errors to application level. */ Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-good/-/merge_requests/885>
This commit is contained in:
parent
fc5a1e468b
commit
c7356c70ee
1 changed files with 10 additions and 0 deletions
|
@ -6703,6 +6703,16 @@ error_response:
|
|||
case GST_RTSP_STS_NOT_ACCEPTABLE:
|
||||
case GST_RTSP_STS_NOT_IMPLEMENTED:
|
||||
case GST_RTSP_STS_METHOD_NOT_ALLOWED:
|
||||
/* Some cameras (e.g. HikVision DS-2CD2732F-IS) return "551
|
||||
* Option not supported" when a command is sent that is not implemented
|
||||
* (e.g. PAUSE). Instead; it should return "501 Not Implemented".
|
||||
*
|
||||
* This is wrong, as previously, the camera did announce support
|
||||
* for PAUSE in the OPTIONS.
|
||||
*
|
||||
* In this case, handle the 551 as if it was 501 to avoid throwing
|
||||
* errors to application level. */
|
||||
case GST_RTSP_STS_OPTION_NOT_SUPPORTED:
|
||||
GST_WARNING_OBJECT (src, "got NOT IMPLEMENTED, disable method %s",
|
||||
gst_rtsp_method_as_text (method));
|
||||
src->methods &= ~method;
|
||||
|
|
Loading…
Reference in a new issue