Browse code

Minor cleanup in push.c

Signed-off-by: Arne Schwabe <arne@rfc2549.org>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20200810143707.5834-5-arne@rfc2549.org>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg20678.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>

Arne Schwabe authored on 2020/08/10 23:36:54
Showing 1 changed files
... ...
@@ -330,15 +330,12 @@ incoming_push_message(struct context *c, const struct buffer *buffer)
330 330
 {
331 331
     struct gc_arena gc = gc_new();
332 332
     unsigned int option_types_found = 0;
333
-    int status;
334 333
 
335 334
     msg(D_PUSH, "PUSH: Received control message: '%s'", sanitize_control_message(BSTR(buffer), &gc));
336 335
 
337
-    status = process_incoming_push_msg(c,
338
-                                       buffer,
339
-                                       c->options.pull,
340
-                                       pull_permission_mask(c),
341
-                                       &option_types_found);
336
+    int status = process_incoming_push_msg(c, buffer, c->options.pull,
337
+                                           pull_permission_mask(c),
338
+                                           &option_types_found);
342 339
 
343 340
     if (status == PUSH_MSG_ERROR)
344 341
     {
... ...
@@ -866,7 +863,7 @@ process_incoming_push_msg(struct context *c,
866 866
         return process_incoming_push_request(c);
867 867
     }
868 868
     else if (honor_received_options
869
-             && buf_string_compare_advance(&buf, "PUSH_REPLY"))
869
+             && buf_string_compare_advance(&buf, push_reply_cmd))
870 870
     {
871 871
         return process_incoming_push_reply(c, permission_mask,
872 872
                                            option_types_found, &buf);