Remove ->shutdown of struct receiver.
authorAndre Noll <maan@systemlinux.org>
Tue, 12 Jan 2010 23:33:47 +0000 (00:33 +0100)
committerAndre Noll <maan@systemlinux.org>
Tue, 12 Jan 2010 23:33:47 +0000 (00:33 +0100)
All three shutdown functions are stubs.

dccp_recv.c
http_recv.c
recv.c
recv.h
udp_recv.c

index 4e1860e..a5a648b 100644 (file)
@@ -87,11 +87,6 @@ err:
        return ret;
 }
 
-static void dccp_shutdown(void)
-{
-       ; /* nothing to do */
-}
-
 static void *dccp_recv_parse_config(int argc, char **argv)
 {
        struct dccp_recv_args_info *tmp = para_calloc(sizeof(struct dccp_recv_args_info));
@@ -153,7 +148,6 @@ void dccp_recv_init(struct receiver *r)
        struct dccp_recv_args_info dummy;
 
        dccp_recv_cmdline_parser_init(&dummy);
-       r->shutdown = dccp_shutdown;
        r->open = dccp_recv_open;
        r->close = dccp_recv_close;
        r->pre_select = dccp_recv_pre_select;
index def5e62..a8c982e 100644 (file)
@@ -68,11 +68,6 @@ struct private_http_recv_data {
        struct btr_pool *btrp;
 };
 
-static void http_shutdown(void)
-{
-       return;
-}
-
 static char *make_request_msg(void)
 {
        char *ret, *hn = para_hostname();
@@ -243,7 +238,6 @@ void http_recv_init(struct receiver *r)
        r->close = http_recv_close;
        r->pre_select = http_recv_pre_select;
        r->post_select = http_recv_post_select;
-       r->shutdown = http_shutdown;
        r->parse_config = http_recv_parse_config;
        r->free_config = http_recv_free_config;
        r->help = (struct ggo_help) {
diff --git a/recv.c b/recv.c
index ca50556..803965c 100644 (file)
--- a/recv.c
+++ b/recv.c
@@ -122,8 +122,6 @@ out:
                btr_free_node(sot.btrn);
        }
        free(rn.conf);
-       if (r)
-               r->shutdown();
        if (ret < 0)
                PARA_ERROR_LOG("%s\n", para_strerror(-ret));
        return ret < 0? EXIT_FAILURE : EXIT_SUCCESS;
diff --git a/recv.h b/recv.h
index 3f13f10..20dd9b8 100644 (file)
--- a/recv.h
+++ b/recv.h
@@ -78,12 +78,6 @@ struct receiver {
         * \sa receiver_node.
         */
        void (*close)(struct receiver_node *rn);
-       /**
-        * Deactivate the receiver.
-        *
-        * Clean up what init has allocated.
-        */
-       void (*shutdown)(void);
        /**
         * Add file descriptors to fd_sets and compute timeout for select(2).
         *
index eb641d8..6637988 100644 (file)
@@ -152,11 +152,6 @@ static void udp_recv_post_select(__a_unused struct sched *s, struct task *t)
        udp_recv_post_select_nobtr(s, t);
 }
 
-static void udp_shutdown(void)
-{
-       return;
-}
-
 static void udp_recv_close(struct receiver_node *rn)
 {
        struct private_udp_recv_data *purd = rn->private_data;
@@ -296,7 +291,6 @@ void udp_recv_init(struct receiver *r)
        struct udp_recv_args_info dummy;
 
        udp_recv_cmdline_parser_init(&dummy);
-       r->shutdown = udp_shutdown;
        r->open = udp_recv_open;
        r->close = udp_recv_close;
        r->pre_select = udp_recv_pre_select;