summaryrefslogtreecommitdiffstats
path: root/net/dccp/ipv6.c
diff options
context:
space:
mode:
authorGerrit Renker <gerrit@erg.abdn.ac.uk>2006-11-10 16:08:37 -0200
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-02 21:22:03 -0800
commitcf557926f6955b4c3fa55e81fdb3675e752e8eed (patch)
tree672d24def170058545736be30040ef2249741cc3 /net/dccp/ipv6.c
parentf45b3ec481581f24719d8ab0bc812c02fcedc2bc (diff)
downloadop-kernel-dev-cf557926f6955b4c3fa55e81fdb3675e752e8eed.zip
op-kernel-dev-cf557926f6955b4c3fa55e81fdb3675e752e8eed.tar.gz
[DCCP]: tidy up dccp_v{4,6}_conn_request
This is a code simplification to remove reduplicated code by concentrating and abstracting shared code. Detailed Changes:
Diffstat (limited to 'net/dccp/ipv6.c')
-rw-r--r--net/dccp/ipv6.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/net/dccp/ipv6.c b/net/dccp/ipv6.c
index ed4a502..19a4f76 100644
--- a/net/dccp/ipv6.c
+++ b/net/dccp/ipv6.c
@@ -427,7 +427,6 @@ static struct sock *dccp_v6_hnd_req(struct sock *sk,struct sk_buff *skb)
static int dccp_v6_conn_request(struct sock *sk, struct sk_buff *skb)
{
- struct dccp_sock dp;
struct request_sock *req;
struct dccp_request_sock *dreq;
struct inet6_request_sock *ireq6;
@@ -459,9 +458,10 @@ static int dccp_v6_conn_request(struct sock *sk, struct sk_buff *skb)
if (req == NULL)
goto drop;
- /* FIXME: process options */
+ if (dccp_parse_options(sk, skb))
+ goto drop_and_free;
- dccp_openreq_init(req, &dp, skb);
+ dccp_reqsk_init(req, skb);
if (security_inet_conn_request(sk, skb, req))
goto drop_and_free;
@@ -469,7 +469,6 @@ static int dccp_v6_conn_request(struct sock *sk, struct sk_buff *skb)
ireq6 = inet6_rsk(req);
ipv6_addr_copy(&ireq6->rmt_addr, &skb->nh.ipv6h->saddr);
ipv6_addr_copy(&ireq6->loc_addr, &skb->nh.ipv6h->daddr);
- req->rcv_wnd = dccp_feat_default_sequence_window;
ireq6->pktopts = NULL;
if (ipv6_opt_accepted(sk, skb) ||
OpenPOWER on IntegriCloud