X-Git-Url: http://ftp.safe.ca/?p=safe%2Fjmp%2Flinux-2.6;a=blobdiff_plain;f=net%2Fipv4%2Fip_options.c;h=f906a80d5a87952e408c1507df4b9eb26ad35352;hp=9f02917d6f45319de4680eade1dda3cf3440b050;hb=e905a9edab7f4f14f9213b52234e4a346c690911;hpb=642656518b2e64fd59d9bbd15b6885cac5fe99b1 diff --git a/net/ipv4/ip_options.c b/net/ipv4/ip_options.c index 9f02917..f906a80 100644 --- a/net/ipv4/ip_options.c +++ b/net/ipv4/ip_options.c @@ -8,7 +8,7 @@ * Version: $Id: ip_options.c,v 1.21 2001/09/01 00:31:50 davem Exp $ * * Authors: A.N.Kuznetsov - * + * */ #include @@ -26,7 +26,7 @@ #include #include -/* +/* * Write options to IP header, record destination address to * source route option, address of outgoing interface * (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, } } -/* +/* * Provided (sopt, skb) points to received options, * build in dopt compiled option set appropriate for answering. * i.e. invert SRR option, copy anothers, @@ -85,7 +85,7 @@ void ip_options_build(struct sk_buff * skb, struct ip_options * opt, * NOTE: dopt cannot point to skb. */ -int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb) +int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb) { struct ip_options *sopt; unsigned char *sptr, *dptr; @@ -215,7 +215,7 @@ int ip_options_echo(struct ip_options * dopt, struct sk_buff * skb) * Simple and stupid 8), but the most efficient way. */ -void ip_options_fragment(struct sk_buff * skb) +void ip_options_fragment(struct sk_buff * skb) { unsigned char * optptr = skb->nh.raw + sizeof(struct iphdr); struct ip_options * opt = &(IPCB(skb)->opt); @@ -370,7 +370,7 @@ int ip_options_compile(struct ip_options * opt, struct sk_buff * skb) switch (optptr[3]&0xF) { case IPOPT_TS_TSONLY: opt->ts = optptr - iph; - if (skb) + if (skb) timeptr = (__be32*)&optptr[optptr[2]-1]; opt->ts_needtime = 1; optptr[2] += 4; @@ -448,7 +448,7 @@ int ip_options_compile(struct ip_options * opt, struct sk_buff * skb) goto error; } opt->cipso = optptr - iph; - if (cipso_v4_validate(&optptr)) { + if (cipso_v4_validate(&optptr)) { pp_ptr = optptr; goto error; }