Packet header writing: set empty packet header bit to 0 when appropriate (small optim...