git.samba.org
/
obnox
/
cwrap
/
socket_wrapper.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
98441f8
)
swrap: Make sure cmbuf is not NULL.
author
Andreas Schneider
<asn@samba.org>
Tue, 27 May 2014 07:09:24 +0000
(09:09 +0200)
committer
Andreas Schneider
<asn@samba.org>
Tue, 27 May 2014 07:51:43 +0000
(09:51 +0200)
CID 63532
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
src/socket_wrapper.c
patch
|
blob
|
history
diff --git
a/src/socket_wrapper.c
b/src/socket_wrapper.c
index 7275e73afef1b50cbb0c658bdf0308e8ea4b33f5..b8b1ca35fdc8f560fa89c23d43ff44a1fb0798c4 100644
(file)
--- a/
src/socket_wrapper.c
+++ b/
src/socket_wrapper.c
@@
-3441,7
+3441,7
@@
static ssize_t swrap_sendmsg_before(int fd,
if (cmlen == 0) {
msg->msg_controllen = 0;
msg->msg_control = NULL;
- } else if (cmlen < msg->msg_controllen) {
+ } else if (cmlen < msg->msg_controllen
&& cmbuf != NULL
) {
memcpy(msg->msg_control, cmbuf, cmlen);
msg->msg_controllen = cmlen;
}