Skip to content

Commit 60aa804

Browse files
Colin Ian Kingklassert
authored andcommitted
esp4: remove redundant initialization of pointer esph
Pointer esph is being assigned a value that is never read, esph is re-assigned and only read inside an if statement, hence the initialization is redundant and can be removed. Cleans up clang warning: net/ipv4/esp4.c:657:21: warning: Value stored to 'esph' during its initialization is never read Signed-off-by: Colin Ian King <[email protected]> Signed-off-by: Steffen Klassert <[email protected]>
1 parent cf19e5e commit 60aa804

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/ipv4/esp4.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -654,7 +654,7 @@ static void esp_input_restore_header(struct sk_buff *skb)
654654
static void esp_input_set_header(struct sk_buff *skb, __be32 *seqhi)
655655
{
656656
struct xfrm_state *x = xfrm_input_state(skb);
657-
struct ip_esp_hdr *esph = (struct ip_esp_hdr *)skb->data;
657+
struct ip_esp_hdr *esph;
658658

659659
/* For ESN we move the header forward by 4 bytes to
660660
* accomodate the high bits. We will move it back after

0 commit comments

Comments
 (0)