Skip to content

Commit

Permalink
af_packet: fix freeing pg_vec twice on error path
Browse files Browse the repository at this point in the history
It is introduced in:
        commit 0e3125c
        Author: Neil Horman <nhorman@tuxdriver.com>
        Date:   Tue Nov 16 10:26:47 2010 -0800

        packet: Enhance AF_PACKET implementation to not require high order contiguous memory allocation (v4)

Signed-off-by: Changli Gao <xiaosuo@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Changli Gao authored and David S. Miller committed Dec 8, 2010
1 parent f6dafa9 commit 920b8d9
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion net/packet/af_packet.c
Original file line number Diff line number Diff line change
Expand Up @@ -2409,7 +2409,6 @@ static struct pgv *alloc_pg_vec(struct tpacket_req *req, int order)

out_free_pgvec:
free_pg_vec(pg_vec, order, block_nr);
kfree(pg_vec);
pg_vec = NULL;
goto out;
}
Expand Down

0 comments on commit 920b8d9

Please sign in to comment.