Attention is currently required from: flichtenheld, plaisthos.
Hello plaisthos,
I'd like you to reexamine a change. Please visit
http://gerrit.openvpn.net/c/openvpn/+/1298?usp=email
to look at the new patch set (#4).
The following approvals got outdated and were removed:
Code-Review-1 by plaisthos
Change subject: ssl: Fix conversion warning in tls_prepend_opcode_v1
......................................................................
ssl: Fix conversion warning in tls_prepend_opcode_v1
Document assumption with ASSERT.
Change-Id: I34584f695ddca3b3e1f2bbcb4380ac91b09c1c8d
Signed-off-by: Frank Lichtenheld <[email protected]>
---
M src/openvpn/ssl.c
1 file changed, 6 insertions(+), 6 deletions(-)
git pull ssh://gerrit.openvpn.net:29418/openvpn refs/changes/98/1298/4
diff --git a/src/openvpn/ssl.c b/src/openvpn/ssl.c
index eb5c4fc..7b93ebc 100644
--- a/src/openvpn/ssl.c
+++ b/src/openvpn/ssl.c
@@ -3970,24 +3970,24 @@
}
}
+#if defined(__GNUC__) || defined(__clang__)
+#pragma GCC diagnostic pop
+#endif
+
void
tls_prepend_opcode_v1(const struct tls_multi *multi, struct buffer *buf)
{
struct key_state *ks = multi->save_ks;
- uint8_t op;
msg(D_TLS_DEBUG, __func__);
ASSERT(ks);
+ ASSERT(ks->key_id <= P_KEY_ID_MASK);
- op = (P_DATA_V1 << P_OPCODE_SHIFT) | ks->key_id;
+ uint8_t op = (P_DATA_V1 << P_OPCODE_SHIFT) | (uint8_t)ks->key_id;
ASSERT(buf_write_prepend(buf, &op, 1));
}
-#if defined(__GNUC__) || defined(__clang__)
-#pragma GCC diagnostic pop
-#endif
-
void
tls_prepend_opcode_v2(const struct tls_multi *multi, struct buffer *buf)
{
--
To view, visit http://gerrit.openvpn.net/c/openvpn/+/1298?usp=email
To unsubscribe, or for help writing mail filters, visit
http://gerrit.openvpn.net/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: openvpn
Gerrit-Branch: master
Gerrit-Change-Id: I34584f695ddca3b3e1f2bbcb4380ac91b09c1c8d
Gerrit-Change-Number: 1298
Gerrit-PatchSet: 4
Gerrit-Owner: flichtenheld <[email protected]>
Gerrit-Reviewer: plaisthos <[email protected]>
Gerrit-CC: openvpn-devel <[email protected]>
Gerrit-Attention: plaisthos <[email protected]>
Gerrit-Attention: flichtenheld <[email protected]>
_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel