added packet handler, linux version