aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2023-07-24 04:31:03 +0000
committerNIIBE Yutaka <[email protected]>2023-07-24 04:31:03 +0000
commitc14409b6b4eb7b914c41c7d7f67137e315c935d9 (patch)
tree1dc796cb0871bb07313884d652cfc9fe87f634df
parentbuild: Prepare release with API change. (diff)
downloadlibassuan-c14409b6b4eb7b914c41c7d7f67137e315c935d9.tar.gz
libassuan-c14409b6b4eb7b914c41c7d7f67137e315c935d9.zip
socket: Don't call pre/post_syscall for bind.
* src/assuan-socket.c (_assuan_sock_bind): Don't call _assuan_pre_syscall and _assuan_post_syscall. -- In the current use cases in GnuPG, the socket is bound *before* calling npth_init and gpgrt_set_syscall_clamp, which results no syscall clamping. It's OK for bind to use with no syscall clamping as it is not blocked longer. Fixes-commit: 703b4100a4162216314d3489fa9d3160c3aadeb5 Signed-off-by: NIIBE Yutaka <[email protected]>
-rw-r--r--src/assuan-socket.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/src/assuan-socket.c b/src/assuan-socket.c
index 0c136dc..8e757b9 100644
--- a/src/assuan-socket.c
+++ b/src/assuan-socket.c
@@ -1210,8 +1210,6 @@ _assuan_sock_bind (assuan_context_t ctx, assuan_fd_t sockfd,
{
int res;
- _assuan_pre_syscall ();
-
#ifdef HAVE_W32_SYSTEM
if (addr->sa_family == AF_LOCAL || addr->sa_family == AF_UNIX)
{
@@ -1306,7 +1304,6 @@ _assuan_sock_bind (assuan_context_t ctx, assuan_fd_t sockfd,
res = bind (sockfd, addr, addrlen);
#endif
- _assuan_post_syscall ();
return res;
}