Attention is currently required from: cron2, plaisthos. flichtenheld has posted comments on this change. ( http://gerrit.openvpn.net/c/openvpn/+/268?usp=email )
Change subject: Change type of frame.mss_fix to uint16_t ...................................................................... Patch Set 4: (2 comments) File src/openvpn/mss.c: http://gerrit.openvpn.net/c/openvpn/+/268/comment/e08cbc9f_bc6cb983 : PS3, Line 195: mssval += opt[3]; > why is this change needed? This fixes a conversion warning: ../../../src/openvpn/mss.c:196:26: warning: conversion from ‘int’ to ‘uint16_t’ {aka ‘short unsigned int’} may change value [-Wconversion] 196 | mssval = (opt[2] << 8) + opt[3]; | ^ So basically the compiler goes up to int and then realizes it needs to go back down to uint16_t. By splitting the statement this is avoided. One could also fix that with casts, but that would be much uglier, IMHO. File src/openvpn/options.c: http://gerrit.openvpn.net/c/openvpn/+/268/comment/d77550a7_9c8eca27 : PS3, Line 7257: if (mssfix > UINT16_MAX) > If we introduce a check here, we should also ensure a minimum value - we > assign `ce. […] Done -- To view, visit http://gerrit.openvpn.net/c/openvpn/+/268?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: Id8321dfbb8ad8d79f4bb2a9da61f8cd6b6c6ee26 Gerrit-Change-Number: 268 Gerrit-PatchSet: 4 Gerrit-Owner: flichtenheld <fr...@lichtenheld.com> Gerrit-Reviewer: cron2 <g...@greenie.muc.de> Gerrit-Reviewer: plaisthos <arne-open...@rfc2549.org> Gerrit-CC: openvpn-devel <openvpn-devel@lists.sourceforge.net> Gerrit-Attention: plaisthos <arne-open...@rfc2549.org> Gerrit-Attention: cron2 <g...@greenie.muc.de> Gerrit-Comment-Date: Sun, 08 Oct 2023 10:44:02 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: cron2 <g...@greenie.muc.de> Gerrit-MessageType: comment
_______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel