Little bug fixes for gp