Closed jeffhiltz closed 11 years ago
Interestingly on Windows I don't get any errors, but nothing is returned as well. I'll fix it soon, thanks for reporting.
// throws "Malformed protocol buffer"
newObj = pb.Parse(new Buffer("Bad buffer"), "Test")
// throws "First argument must be a Buffer"
newObj = pb.Parse("Bad argument", "Test")
There is a chance that the protobuf data that I'm trying to parse is invalid. If I pass invalid data to the Parse function (as in sample below) I get a segmentation fault.
Would it be possible to catch the fault and return an Error object or throw an Error?
Thanks.