Fix memory problem in ip.c
extract buffer_pool from packet