summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Kjellerstedt <pkj@axis.com>2009-06-09 16:37:09 +0200
committerPeter Kjellerstedt <pkj@axis.com>2009-06-17 18:02:18 +0200
commit595f8b6d005a6c0653301f9caabdc1ed06092a84 (patch)
tree24b5ae3e8b15221cf0d26b918f829002615bd2c2
parentddbeb44f14ab53c41a4f79a34f06b501f27f10c9 (diff)
rtsp: Only extract the session ID from RTSP responses.
-rw-r--r--gst-libs/gst/rtsp/gstrtspconnection.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gst-libs/gst/rtsp/gstrtspconnection.c b/gst-libs/gst/rtsp/gstrtspconnection.c
index db4867d01..990fa5656 100644
--- a/gst-libs/gst/rtsp/gstrtspconnection.c
+++ b/gst-libs/gst/rtsp/gstrtspconnection.c
@@ -1722,7 +1722,8 @@ build_next (GstRTSPBuilder * builder, GstRTSPMessage * message,
}
/* save session id in the connection for further use */
- if (gst_rtsp_message_get_header (message, GST_RTSP_HDR_SESSION,
+ if (message->type == GST_RTSP_MESSAGE_RESPONSE &&
+ gst_rtsp_message_get_header (message, GST_RTSP_HDR_SESSION,
&session_id, 0) == GST_RTSP_OK) {
gint maxlen, i;