if (!cookie_timestamp_decode(net, &tcp_opt))
                goto out;
 
-       ret = NULL;
        req = cookie_tcp_reqsk_alloc(&tcp_request_sock_ops,
                                     &tcp_request_sock_ipv4_ops, sk, skb);
        if (!req)
-               goto out;
+               goto out_drop;
 
        ireq = inet_rsk(req);
        treq = tcp_rsk(req);
         */
        RCU_INIT_POINTER(ireq->ireq_opt, tcp_v4_save_options(net, skb));
 
-       if (security_inet_conn_request(sk, skb, req)) {
-               reqsk_free(req);
-               goto out;
-       }
+       if (security_inet_conn_request(sk, skb, req))
+               goto out_free;
 
        req->num_retrans = 0;
 
                           ireq->ir_loc_addr, th->source, th->dest, sk->sk_uid);
        security_req_classify_flow(req, flowi4_to_flowi_common(&fl4));
        rt = ip_route_output_key(net, &fl4);
-       if (IS_ERR(rt)) {
-               reqsk_free(req);
-               goto out;
-       }
+       if (IS_ERR(rt))
+               goto out_free;
 
        /* Try to redo what tcp_v4_send_synack did. */
        req->rsk_window_clamp = tp->window_clamp ? :dst_metric(&rt->dst, RTAX_WINDOW);
         */
        if (ret)
                inet_sk(ret)->cork.fl.u.ip4 = fl4;
-out:   return ret;
+out:
+       return ret;
+out_free:
+       reqsk_free(req);
+out_drop:
+       return NULL;
 }
 
        if (!cookie_timestamp_decode(net, &tcp_opt))
                goto out;
 
-       ret = NULL;
        req = cookie_tcp_reqsk_alloc(&tcp6_request_sock_ops,
                                     &tcp_request_sock_ipv6_ops, sk, skb);
        if (!req)
-               goto out;
+               goto out_drop;
 
        ireq = inet_rsk(req);
        treq = tcp_rsk(req);
        return ret;
 out_free:
        reqsk_free(req);
+out_drop:
        return NULL;
 }