X-Git-Url: http://p2p-next.cs.pub.ro/gitweb/?a=blobdiff_plain;f=src%2Fkernel%2Fswift.c;h=b3aa899650e60031a588f27acf66243ea48d7506;hb=a15b02688842af2b3fad741eeefc1ab4c513b555;hp=1a7e164d91103e69e22c804b7aa3c7d00a2a4b0c;hpb=bbca8085b73e72dc3a5eabb97a96e3c3b3d03577;p=swifty.git diff --git a/src/kernel/swift.c b/src/kernel/swift.c index 1a7e164..b3aa899 100644 --- a/src/kernel/swift.c +++ b/src/kernel/swift.c @@ -1,4 +1,5 @@ #include +#include #include #include #include @@ -310,7 +311,11 @@ static int swift_sendmsg(struct kiocb *iocb, struct socket *sock, struct msghdr log_error("Route lookup failed\n"); goto out_free; } +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 36) + sk_dst_set(sk, dst_clone(&rt->u.dst)); +#else sk_dst_set(sk, dst_clone(&rt->dst)); +#endif } err = ip_queue_xmit(skb);