X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=datapath%2Factions.c;fp=datapath%2Factions.c;h=a21bce840797da4946eb149ade5e4b9155496a46;hb=985224ac0c6a2eeebf71c58b12893eafe2386a3d;hp=8a3e8abb549e1302bdbed626bd889728bf2854f5;hpb=fb344b867b96a6d6b9ec32e277cae6db68f2f236;p=sliver-openvswitch.git diff --git a/datapath/actions.c b/datapath/actions.c index 8a3e8abb5..a21bce840 100644 --- a/datapath/actions.c +++ b/datapath/actions.c @@ -259,8 +259,8 @@ set_tp_port(struct sk_buff *skb, struct odp_flow_key *key, u16 *f = a->type == ODPAT_SET_TP_SRC ? &th->source : &th->dest; u16 old = *f; u16 new = a->tp_port; - update_csum((u16*)((u8*)skb->data + check_ofs), - skb, old, new, 1); + update_csum((u16*)(skb_transport_header(skb) + check_ofs), + skb, old, new, 1); *f = new; } return skb;