aboutsummaryrefslogtreecommitdiffstats
path: root/net/dccp/proto.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@mandriva.com>2006-03-21 01:00:37 -0500
committerDavid S. Miller <davem@davemloft.net>2006-03-21 01:00:37 -0500
commit72478873571d869906f7a250b09e12fa5b65e321 (patch)
tree562e6179922a5eef9c1f3eb7b1bf3813a6e53545 /net/dccp/proto.c
parentc25a18ba347f091d1ce620ba33e6772b60a528e1 (diff)
[DCCP] ipv6: Add missing ipv6 control socket
I guess I forgot to add it, nah, now it just works: 18:04:33.274066 IP6 ::1.1476 > ::1.5001: request (service=0) 18:04:33.334482 IP6 ::1.5001 > ::1.1476: reset (code=bad_service_code) Ditched IP_DCCP_UNLOAD_HACK, as now we would have to do it for both IPv6 and IPv4, so I'll come up with another way for freeing the control sockets in upcoming changesets. Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dccp/proto.c')
-rw-r--r--net/dccp/proto.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/net/dccp/proto.c b/net/dccp/proto.c
index f644c1a23c4d..baccaf35ffbd 100644
--- a/net/dccp/proto.c
+++ b/net/dccp/proto.c
@@ -163,11 +163,10 @@ void dccp_unhash(struct sock *sk)
163 163
164EXPORT_SYMBOL_GPL(dccp_unhash); 164EXPORT_SYMBOL_GPL(dccp_unhash);
165 165
166int dccp_init_sock(struct sock *sk) 166int dccp_init_sock(struct sock *sk, const __u8 ctl_sock_initialized)
167{ 167{
168 struct dccp_sock *dp = dccp_sk(sk); 168 struct dccp_sock *dp = dccp_sk(sk);
169 struct inet_connection_sock *icsk = inet_csk(sk); 169 struct inet_connection_sock *icsk = inet_csk(sk);
170 static int dccp_ctl_socket_init = 1;
171 170
172 dccp_options_init(&dp->dccps_options); 171 dccp_options_init(&dp->dccps_options);
173 do_gettimeofday(&dp->dccps_epoch); 172 do_gettimeofday(&dp->dccps_epoch);
@@ -179,7 +178,7 @@ int dccp_init_sock(struct sock *sk)
179 * lets leave it here, later the real solution is to do this in a 178 * lets leave it here, later the real solution is to do this in a
180 * setsockopt(CCIDs-I-want/accept). -acme 179 * setsockopt(CCIDs-I-want/accept). -acme
181 */ 180 */
182 if (likely(!dccp_ctl_socket_init)) { 181 if (likely(ctl_sock_initialized)) {
183 int rc = dccp_feat_init(sk); 182 int rc = dccp_feat_init(sk);
184 183
185 if (rc) 184 if (rc)
@@ -211,7 +210,6 @@ int dccp_init_sock(struct sock *sk)
211 /* control socket doesn't need feat nego */ 210 /* control socket doesn't need feat nego */
212 INIT_LIST_HEAD(&dp->dccps_options.dccpo_pending); 211 INIT_LIST_HEAD(&dp->dccps_options.dccpo_pending);
213 INIT_LIST_HEAD(&dp->dccps_options.dccpo_conf); 212 INIT_LIST_HEAD(&dp->dccps_options.dccpo_conf);
214 dccp_ctl_socket_init = 0;
215 } 213 }
216 214
217 dccp_init_xmit_timers(sk); 215 dccp_init_xmit_timers(sk);