catch boost exceptions