1CURLOPT_RTSP_SESSION_ID(3) curl_easy_setopt options CURLOPT_RTSP_SESSION_ID(3)
2
3
4

NAME

6       CURLOPT_RTSP_SESSION_ID - set RTSP session ID
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       CURLcode  curl_easy_setopt(CURL  *handle, CURLOPT_RTSP_SESSION_ID, char
12       *id);
13

DESCRIPTION

15       Pass a char * as a parameter to set the value of the current RTSP  Ses‐
16       sion  ID  for  the  handle. Useful for resuming an in-progress session.
17       Once this value is set to  any  non-NULL  value,  libcurl  will  return
18       CURLE_RTSP_SESSION_ERROR if ID received from the server does not match.
19       If unset (or set to NULL), libcurl will automatically set  the  ID  the
20       first time the server sets it in a response.
21
22       The  application  does not have to keep the string around after setting
23       this option.
24

DEFAULT

26       NULL
27

PROTOCOLS

29       RTSP
30

EXAMPLE

32       CURL *curl = curl_easy_init();
33       if(curl) {
34         char *prev_id; /* saved from before somehow */
35         curl_easy_setopt(curl, CURLOPT_URL, "rtsp://example.com/");
36         curl_easy_setopt(curl, CURLOPT_RTSP_SESSION_ID, prev_id);
37         ret = curl_easy_perform(curl);
38         curl_easy_cleanup(curl);
39       }
40

AVAILABILITY

42       Added in 7.20.0
43

RETURN VALUE

45       Returns CURLE_OK if the option is  supported,  CURLE_UNKNOWN_OPTION  if
46       not, or CURLE_OUT_OF_MEMORY if there was insufficient heap space.
47

SEE ALSO

49       CURLOPT_RTSP_REQUEST(3), CURLOPT_RTSP_STREAM_URI(3),
50
51
52
53libcurl 7.71.1                   May 31, 2017       CURLOPT_RTSP_SESSION_ID(3)
Impressum