Skip to content

Commit c3600e9

Browse files
mrbffcron2
authored andcommitted
push-update-server: comment about buf_string_compare_advance() usage in send_single_push_update()
Change-Id: I73f8ad9bf105920f4bde357ea9dcf0e485f3f3cb Signed-off-by: Marco Baffo <[email protected]> Acked-by: Frank Lichtenheld <[email protected]> Message-Id: <[email protected]> URL: https://sourceforge.net/p/openvpn/mailman/message/59232447/ URL: https://gerrit.openvpn.net/c/openvpn/+/1177 Signed-off-by: Gert Doering <[email protected]>
1 parent 3b42992 commit c3600e9

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/openvpn/push_util.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,10 @@ send_single_push_update(struct context *c, struct buffer *msgs, unsigned int *op
161161
* will not be routed towards the client.
162162
* For the same reason we later update the vhash too in
163163
* `send_push_update()` function.
164+
* Using `buf_string_compare_advance()` we mimic the behavior
165+
* inside `process_incoming_push_msg()`. However, we don't need
166+
* to check the return value here because we just want to `advance`,
167+
* meaning we skip the `push_update_cmd' we added earlier.
164168
*/
165169
buf_string_compare_advance(&msgs[i], push_update_cmd);
166170
if (process_incoming_push_update(c, pull_permission_mask(c), option_types_found, &msgs[i], true) == PUSH_MSG_ERROR)

0 commit comments

Comments
 (0)