projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Cleanup: remove duplicated implementation of rculfhash
[lttng-tools.git]
/
src
/
common
/
sessiond-comm
/
inet.c
diff --git
a/src/common/sessiond-comm/inet.c
b/src/common/sessiond-comm/inet.c
index cf06ecb858d2079455c7a009f888435b6532d6c4..2703a666e71e557c10b956bb2c0402d89ca1aec9 100644
(file)
--- a/
src/common/sessiond-comm/inet.c
+++ b/
src/common/sessiond-comm/inet.c
@@
-16,6
+16,7
@@
*/
#define _GNU_SOURCE
*/
#define _GNU_SOURCE
+#define _LGPL_SOURCE
#include <assert.h>
#include <limits.h>
#include <stdio.h>
#include <assert.h>
#include <limits.h>
#include <stdio.h>
@@
-305,11
+306,11
@@
struct lttcomm_sock *lttcomm_accept_inet_sock(struct lttcomm_sock *sock)
ret = lttcomm_setsockopt_rcv_timeout(new_fd, timeout);
if (ret) {
ret = lttcomm_setsockopt_rcv_timeout(new_fd, timeout);
if (ret) {
- goto error;
+ goto error
_close
;
}
ret = lttcomm_setsockopt_snd_timeout(new_fd, timeout);
if (ret) {
}
ret = lttcomm_setsockopt_snd_timeout(new_fd, timeout);
if (ret) {
- goto error;
+ goto error
_close
;
}
}
}
}
@@
-319,6
+320,11
@@
struct lttcomm_sock *lttcomm_accept_inet_sock(struct lttcomm_sock *sock)
end:
return new_sock;
end:
return new_sock;
+error_close:
+ if (close(new_fd) < 0) {
+ PERROR("accept inet close fd");
+ }
+
error:
free(new_sock);
return NULL;
error:
free(new_sock);
return NULL;
This page took
0.024461 seconds
and
4
git commands to generate.