Make BgpProtoPrefix parsing more robust

Change-Id: I0f2b8f39ff6ccfc1ad0c42438e472fca552cf229