Tue May 12 13:23:33 CDT 2009 Pekka Pessi <first.last@nokia.com>

* tport.c: do not use out-of-scope array in tport_deliver()
  Ignore-this: a651d5eb213850d9dfd317102a432f8e
  
  Coverity issue.


git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13331 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Michael Jerris 2009-05-15 16:01:31 +00:00
parent 9a38d3da7d
commit 61c7a110b2
2 changed files with 5 additions and 5 deletions

View File

@ -1 +1 @@
Fri May 15 10:59:42 CDT 2009
Fri May 15 11:01:11 CDT 2009

View File

@ -2952,6 +2952,7 @@ void tport_deliver(tport_t *self,
tport_t *ref;
int error;
struct tport_delivery *d;
char ipaddr[SU_ADDRSIZE + 2];
assert(msg);
@ -2962,7 +2963,6 @@ void tport_deliver(tport_t *self,
*d->d_from = *self->tp_name;
if (tport_is_primary(self)) {
char ipaddr[SU_ADDRSIZE + 2];
su_sockaddr_t const *su = msg_addr(msg);
#if SU_HAVE_IN6
@ -3005,16 +3005,16 @@ void tport_deliver(tport_t *self,
ref = tport_incref(self);
if (self->tp_pri->pri_vtable->vtp_deliver) {
self->tp_pri->pri_vtable->vtp_deliver(self, msg, now);
}
else
tport_base_deliver(self, msg, now);
tport_decref(&ref);
memset(d->d_from, 0, sizeof d->d_from);
d->d_msg = NULL;
tport_decref(&ref);
}
/** Pass message to the protocol stack */