git: 108d740adff2 - stable/13 - sctp: cleanup, no functional change
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 01 Feb 2023 22:30:41 UTC
The branch stable/13 has been updated by tuexen:
URL: https://cgit.FreeBSD.org/src/commit/?id=108d740adff29f694a023e427966454a7211f270
commit 108d740adff29f694a023e427966454a7211f270
Author: Michael Tuexen <tuexen@FreeBSD.org>
AuthorDate: 2022-04-02 21:02:16 +0000
Commit: Michael Tuexen <tuexen@FreeBSD.org>
CommitDate: 2023-02-01 22:30:21 +0000
sctp: cleanup, no functional change
(cherry picked from commit b30b7a140c527c023f97083c256715ea86d4b6f4)
---
sys/netinet/sctp_output.c | 26 ++++++++++----------------
1 file changed, 10 insertions(+), 16 deletions(-)
diff --git a/sys/netinet/sctp_output.c b/sys/netinet/sctp_output.c
index d0cebba4335b..3458da7e0578 100644
--- a/sys/netinet/sctp_output.c
+++ b/sys/netinet/sctp_output.c
@@ -13358,21 +13358,7 @@ skip_preblock:
error = be.error;
}
}
- if (error != 0) {
- SOCKBUF_UNLOCK(&so->so_snd);
- SCTP_TCB_LOCK(stcb);
- hold_tcblock = true;
- stcb->block_entry = NULL;
- if (((asoc->state & SCTP_STATE_ABOUT_TO_BE_FREED) == 0) &&
- ((asoc->state & SCTP_STATE_WAS_ABORTED) == 0) &&
- (sp != NULL)) {
- sp->processing = 0;
- }
- goto out_unlocked;
- }
- }
- SOCKBUF_UNLOCK(&so->so_snd);
- if (!hold_tcblock) {
+ SOCKBUF_UNLOCK(&so->so_snd);
SCTP_TCB_LOCK(stcb);
hold_tcblock = true;
stcb->block_entry = NULL;
@@ -13388,8 +13374,16 @@ skip_preblock:
} else {
error = ENOTCONN;
}
- goto out;
+ goto out_unlocked;
+ }
+ if (error != 0) {
+ if (sp != NULL) {
+ sp->processing = 0;
+ }
+ goto out_unlocked;
}
+ } else {
+ SOCKBUF_UNLOCK(&so->so_snd);
}
if (SCTP_BASE_SYSCTL(sctp_logging_level) & SCTP_BLK_LOGGING_ENABLE) {
sctp_log_block(SCTP_BLOCK_LOG_OUTOF_BLK,