summaryrefslogtreecommitdiff
path: root/lib/tsocket
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tsocket')
-rw-r--r--lib/tsocket/tsocket_bsd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tsocket/tsocket_bsd.c b/lib/tsocket/tsocket_bsd.c
index 5cd7702ff6b..8d1fe320834 100644
--- a/lib/tsocket/tsocket_bsd.c
+++ b/lib/tsocket/tsocket_bsd.c
@@ -2025,7 +2025,7 @@ static struct tevent_req * tstream_bsd_connect_send(TALLOC_CTX *mem_ctx,
}
if (do_bind) {
- ret = bind(state->fd, &lbsda->u.sa, sizeof(lbsda->u.ss));
+ ret = bind(state->fd, &lbsda->u.sa, sa_socklen);
if (ret == -1) {
tevent_req_error(req, errno);
goto post;