aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-02-12 21:41:01 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-02-12 21:41:01 +0000
commite1db2e3c5a3f2b8113008b74a06c487000ebaa5d (patch)
tree19cd6c0c2e7016ac9f681f2ef3e405f334963b10 /channels
parente6fb59edcaec38ea97dc381e12290cf0a7c5ee13 (diff)
Remove useless string copy, and make sscanf safe again
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@175368 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index b5dbdeca8..f0a7fb9e3 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -7671,7 +7671,6 @@ static int process_sdp(struct sip_pvt *p, struct sip_request *req, int t38action
iterator = req->sdp_start;
while ((a = get_sdp_iterate(&iterator, req, "a"))[0] != '\0') {
char mimeSubtype[128];
- ast_copy_string(mimeSubtype, a, sizeof(mimeSubtype));
if (option_debug > 1) {
int breakout = FALSE;
@@ -7759,7 +7758,7 @@ static int process_sdp(struct sip_pvt *p, struct sip_request *req, int t38action
}
red_cp = red_fmtp;
- } else if (sscanf(a, "rtpmap: %u %[^/]/", &codec, mimeSubtype) == 2) {
+ } else if (sscanf(a, "rtpmap: %u %127[^/]/", &codec, mimeSubtype) == 2) {
/* We have a rtpmap to handle */
if (last_rtpmap_codec < SDP_MAX_RTPMAP_CODECS) {