Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(raw) check for nullptr in raw input plugin (AcademySoftwareFounda…
…tion#4448) This adds a null pointer check in the raw input plugin when the user requested raw bayer data for a file format which doesn't have it. With this fix OIIO shows an error instead of crashing in such case. This fixes the issue mentioned in the comments of AcademySoftwareFoundation#4361. The title issue of AcademySoftwareFoundation#4361 has been resolved in LibRaw 0.22.0, so we can close that issue, I guess. This also fixes the crash on 5 out of 6 examples in AcademySoftwareFoundation#3115. The last one is unrelated, and I don't have a good fix for that at this time (crash due to the raw buffer having half resolution, with the pixel aspect ratio of 0.5). Perhaps we could create a separate issue and close AcademySoftwareFoundation#3115. I have not added any tests for this change specifically, as it is fairly trivial. I have started working on a more comprehensive test suite for the raw plugin / rawtoaces, but it's not ready yet, and I'm not sure where it should live at this stage. Signed-off-by: Anton Dukhovnikov <[email protected]>
- Loading branch information