diff options
author | rrs <rrs@FreeBSD.org> | 2007-06-18 22:36:52 +0000 |
---|---|---|
committer | rrs <rrs@FreeBSD.org> | 2007-06-18 22:36:52 +0000 |
commit | 660ca20248e30a17125dabfcd5a59eb2918f8209 (patch) | |
tree | 66e0abe6d13d9d52b5d234fedb6ebd059794b7c7 /sys | |
parent | 8a0763227685af848068eb5461da992d7cac086b (diff) | |
download | FreeBSD-src-660ca20248e30a17125dabfcd5a59eb2918f8209.zip FreeBSD-src-660ca20248e30a17125dabfcd5a59eb2918f8209.tar.gz |
- Two more static analisys bugs found by cisco's tool on a subsequent
run.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/netinet/sctp_output.c | 5 | ||||
-rw-r--r-- | sys/netinet/sctp_timer.c | 3 |
2 files changed, 5 insertions, 3 deletions
diff --git a/sys/netinet/sctp_output.c b/sys/netinet/sctp_output.c index 77beb1f..ac2da30 100644 --- a/sys/netinet/sctp_output.c +++ b/sys/netinet/sctp_output.c @@ -10436,9 +10436,10 @@ sctp_copy_resume(struct sctp_stream_queue_pending *sp, (M_PKTHDR | (user_marks_eor ? M_EOR : 0))); if (m == NULL) *error = ENOMEM; - else + else { *sndout = m_length(m, NULL); - *new_tail = m_last(m); + *new_tail = m_last(m); + } return (m); } diff --git a/sys/netinet/sctp_timer.c b/sys/netinet/sctp_timer.c index 9e17dd0..380c357 100644 --- a/sys/netinet/sctp_timer.c +++ b/sys/netinet/sctp_timer.c @@ -1706,7 +1706,8 @@ select_a_new_ep: if (iteration_count > SCTP_ITERATOR_MAX_AT_ONCE) { start_timer_return: /* set a timer to continue this later */ - SCTP_TCB_UNLOCK(it->stcb); + if (it->stcb) + SCTP_TCB_UNLOCK(it->stcb); sctp_timer_start(SCTP_TIMER_TYPE_ITERATOR, (struct sctp_inpcb *)it, NULL, NULL); SCTP_ITERATOR_UNLOCK(); |