FreeCalypso > hg > themwi-system-sw
comparison sip-manual-out/disc_cmd.c @ 192:f8a33603288f
sip-manual-out: generate outgoing RTP stream with PCM silence
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Fri, 17 Mar 2023 13:45:31 -0800 |
parents | a36b731bfef9 |
children | 1f9a6cede2c5 |
comparison
equal
deleted
inserted
replaced
191:6ac96217c442 | 192:f8a33603288f |
---|---|
12 #include <strings.h> | 12 #include <strings.h> |
13 #include "../libsip/out_msg.h" | 13 #include "../libsip/out_msg.h" |
14 | 14 |
15 extern struct sockaddr_in sip_dest_sin; | 15 extern struct sockaddr_in sip_dest_sin; |
16 extern char to_uri[]; | 16 extern char to_uri[]; |
17 extern int rtp_out_enable; | |
17 | 18 |
18 send_cancel_req() | 19 send_cancel_req() |
19 { | 20 { |
20 struct sip_msg_out msg; | 21 struct sip_msg_out msg; |
21 int rc; | 22 int rc; |
22 | 23 |
24 rtp_out_enable = 0; | |
23 rc = start_request_out_msg(&msg, "CANCEL", to_uri); | 25 rc = start_request_out_msg(&msg, "CANCEL", to_uri); |
24 if (rc < 0) { | 26 if (rc < 0) { |
25 msg_size_err: fprintf(stderr, "composing CANCEL message: size error\n"); | 27 msg_size_err: fprintf(stderr, "composing CANCEL message: size error\n"); |
26 return(-1); | 28 return(-1); |
27 } | 29 } |
36 send_bye_req() | 38 send_bye_req() |
37 { | 39 { |
38 struct sip_msg_out msg; | 40 struct sip_msg_out msg; |
39 int rc; | 41 int rc; |
40 | 42 |
43 rtp_out_enable = 0; | |
41 rc = start_request_out_msg(&msg, "BYE", to_uri); | 44 rc = start_request_out_msg(&msg, "BYE", to_uri); |
42 if (rc < 0) { | 45 if (rc < 0) { |
43 msg_size_err: fprintf(stderr, "composing BYE message: size error\n"); | 46 msg_size_err: fprintf(stderr, "composing BYE message: size error\n"); |
44 return(-1); | 47 return(-1); |
45 } | 48 } |