aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/ip_options.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/ip_options.c')
-rw-r--r--net/ipv4/ip_options.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/net/ipv4/ip_options.c b/net/ipv4/ip_options.c
index 9f02917d6f45..f906a80d5a87 100644
--- a/net/ipv4/ip_options.c
+++ b/net/ipv4/ip_options.c
@@ -8,7 +8,7 @@
8 * Version: $Id: ip_options.c,v 1.21 2001/09/01 00:31:50 davem Exp $ 8 * Version: $Id: ip_options.c,v 1.21 2001/09/01 00:31:50 davem Exp $
9 * 9 *
10 * Authors: A.N.Kuznetsov 10 * Authors: A.N.Kuznetsov
11 * 11 *
12 */ 12 */
13 13
14#include <linux/capability.h> 14#include <linux/capability.h>
@@ -26,7 +26,7 @@
26#include <net/route.h> 26#include <net/route.h>
27#include <net/cipso_ipv4.h> 27#include <net/cipso_ipv4.h>
28 28
29/* 29/*
30 * Write options to IP header, record destination address to 30 * Write options to IP header, record destination address to
31 * source route option, address of outgoing interface 31 * source route option, address of outgoing interface
32 * (we should already know it, so that this function is allowed be 32 * (we should already know it, so that this function is allowed be
@@ -76,7 +76,7 @@ void ip_options_build(struct sk_buff * skb, struct ip_options * opt,
76 } 76 }
77} 77}
78 78
79/* 79/*
80 * Provided (sopt, skb) points to received options, 80 * Provided (sopt, skb) points to received options,
81 * build in dopt compiled option set appropriate for answering. 81 * build in dopt compiled option set appropriate for answering.
82 * i.e. invert SRR option, copy anothers, 82 * i.e. invert SRR option, copy anothers,
@@ -85,7 +85,7 @@ void ip_options_build(struct sk_buff * skb, struct ip_options * opt,
85 * NOTE: dopt cannot point to skb. 85 * NOTE: dopt cannot point to skb.
86 */ 86 */
87 87
88int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb) 88int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb)
89{ 89{
90 struct ip_options *sopt; 90 struct ip_options *sopt;
91 unsigned char *sptr, *dptr; 91 unsigned char *sptr, *dptr;
@@ -215,7 +215,7 @@ int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb)
215 * Simple and stupid 8), but the most efficient way. 215 * Simple and stupid 8), but the most efficient way.
216 */ 216 */
217 217
218void ip_options_fragment(struct sk_buff * skb) 218void ip_options_fragment(struct sk_buff * skb)
219{ 219{
220 unsigned char * optptr = skb->nh.raw + sizeof(struct iphdr); 220 unsigned char * optptr = skb->nh.raw + sizeof(struct iphdr);
221 struct ip_options * opt = &(IPCB(skb)->opt); 221 struct ip_options * opt = &(IPCB(skb)->opt);
@@ -370,7 +370,7 @@ int ip_options_compile(struct ip_options * opt, struct sk_buff * skb)
370 switch (optptr[3]&0xF) { 370 switch (optptr[3]&0xF) {
371 case IPOPT_TS_TSONLY: 371 case IPOPT_TS_TSONLY:
372 opt->ts = optptr - iph; 372 opt->ts = optptr - iph;
373 if (skb) 373 if (skb)
374 timeptr = (__be32*)&optptr[optptr[2]-1]; 374 timeptr = (__be32*)&optptr[optptr[2]-1];
375 opt->ts_needtime = 1; 375 opt->ts_needtime = 1;
376 optptr[2] += 4; 376 optptr[2] += 4;
@@ -448,7 +448,7 @@ int ip_options_compile(struct ip_options * opt, struct sk_buff * skb)
448 goto error; 448 goto error;
449 } 449 }
450 opt->cipso = optptr - iph; 450 opt->cipso = optptr - iph;
451 if (cipso_v4_validate(&optptr)) { 451 if (cipso_v4_validate(&optptr)) {
452 pp_ptr = optptr; 452 pp_ptr = optptr;
453 goto error; 453 goto error;
454 } 454 }