Attention is currently required from: flichtenheld, plaisthos.
Hello plaisthos, flichtenheld,
I'd like you to do a code review.
Please visit
http://gerrit.openvpn.net/c/openvpn/+/900?usp=email
to review the following change.
Change subject: dco-win: simplify control packets prepend code
......................................................................
dco-win: simplify control packets prepend code
Eliminate unneeded temporary struct sockaddr_in buffer.
Change-Id: Ie57f7b11157ab5ca8ff01e1c4f03a308117ff937
Signed-off-by: Lev Stipakov <[email protected]>
---
M src/openvpn/socket.h
1 file changed, 2 insertions(+), 6 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/00/900/1
diff --git a/src/openvpn/socket.h b/src/openvpn/socket.h
index c370f2c..ee04a96 100644
--- a/src/openvpn/socket.h
+++ b/src/openvpn/socket.h
@@ -1125,15 +1125,11 @@
{
if (to->dest.addr.sa.sa_family == AF_INET)
{
- struct sockaddr_in sa;
- memcpy(&sa, &to->dest.addr.in4, sizeof(sa));
- buf_write_prepend(buf, &sa, sizeof(sa));
+ buf_write_prepend(buf, &to->dest.addr.in4, sizeof(struct
sockaddr_in));
}
else
{
- struct sockaddr_in6 sa;
- memcpy(&sa, &to->dest.addr.in6, sizeof(sa));
- buf_write_prepend(buf, &sa, sizeof(sa));
+ buf_write_prepend(buf, &to->dest.addr.in6, sizeof(struct
sockaddr_in6));
}
}
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/900?usp=email
To unsubscribe, or for help writing mail filters, visit
http://gerrit.openvpn.net/settings
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: Ie57f7b11157ab5ca8ff01e1c4f03a308117ff937
Gerrit-Change-Number: 900
Gerrit-PatchSet: 1
Gerrit-Owner: stipa <[email protected]>
Gerrit-Reviewer: flichtenheld <[email protected]>
Gerrit-Reviewer: plaisthos <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]>
Gerrit-Attention: flichtenheld <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel