Unknown error code (0x16) returned by libraw_dcraw_process()

Having correctly unpacked my raw image into raw_image, I tried to use libraw_dcraw_process() to create a debayered image with params.half_size = 1 (as per sample code), but I get a return code 22 (0x16) which libraw_strerror converts to "Unknown error code". Any hints as to what might be wrong?

Forums: 

All LibRaw::dcraw_process()

All LibRaw::dcraw_process() return codes are negative.

A quick look at the source code showed no deviations from this rule.

Could you please provide raw file you're testing with

-- Alex Tutubalin @LibRaw LLC