Make BgpProtoPrefix parsing more robust

Change-Id: If40df9b12ad9b7b52fc70497f09c6f0e40d4e1cf