s3:lib: s/result/req in open_socket_out_send()
authorStefan Metzmacher <metze@samba.org>
Wed, 26 Feb 2020 12:21:15 +0000 (13:21 +0100)
committerJeremy Allison <jra@samba.org>
Wed, 26 Feb 2020 19:45:36 +0000 (19:45 +0000)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/lib/util_sock.c

index 8fd2f7fa3155f70ef1f10bf33d90c86a8d111eae..c6a6c05845d5d8e3d542eda1dd982fa47a76f34b 100644 (file)
@@ -459,13 +459,13 @@ struct tevent_req *open_socket_out_send(TALLOC_CTX *mem_ctx,
                                        int timeout)
 {
        char addr[INET6_ADDRSTRLEN];
-       struct tevent_req *result;
+       struct tevent_req *req;
        struct open_socket_out_state *state;
        NTSTATUS status;
 
-       result = tevent_req_create(mem_ctx, &state,
-                                  struct open_socket_out_state);
-       if (result == NULL) {
+       req = tevent_req_create(mem_ctx, &state,
+                               struct open_socket_out_state);
+       if (req == NULL) {
                return NULL;
        }
        state->ev = ev;
@@ -480,10 +480,10 @@ struct tevent_req *open_socket_out_send(TALLOC_CTX *mem_ctx,
                goto post_status;
        }
 
-       tevent_req_set_cleanup_fn(result, open_socket_out_cleanup);
+       tevent_req_set_cleanup_fn(req, open_socket_out_cleanup);
 
        if (!tevent_req_set_endtime(
-                   result, ev, timeval_current_ofs_msec(timeout))) {
+                   req, ev, timeval_current_ofs_msec(timeout))) {
                goto fail;
        }
 
@@ -524,14 +524,14 @@ struct tevent_req *open_socket_out_send(TALLOC_CTX *mem_ctx,
                goto fail;
        }
        tevent_req_set_callback(state->connect_subreq,
-                               open_socket_out_connected, result);
-       return result;
+                               open_socket_out_connected, req);
+       return req;
 
  post_status:
-       tevent_req_nterror(result, status);
-       return tevent_req_post(result, ev);
+       tevent_req_nterror(req, status);
+       return tevent_req_post(req, ev);
  fail:
-       TALLOC_FREE(result);
+       TALLOC_FREE(req);
        return NULL;
 }