Fix a bug in insert_pv() where minimum depth is zero