Skip to content

Commit

Permalink
fix(exr): allow an empty "name" metadata to be read (AcademySoftwareF…
Browse files Browse the repository at this point in the history
…oundation#4536)

Continuation of PR AcademySoftwareFoundation#4528. I forgot to change the spot in the
OpenEXR "core" API as well.

Signed-off-by: Larry Gritz <lg@larrygritz.com>
  • Loading branch information
lgritz committed Nov 12, 2024
1 parent bc92a46 commit fab3dc2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/openexr.imageio/exrinput_c.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ OpenEXRCoreInput::PartInfo::parse_header(OpenEXRCoreInput* in,
// EXR "name" also gets passed along as "oiio:subimagename".
const char* partname;
if (exr_get_name(ctxt, subimage, &partname) == EXR_ERR_SUCCESS) {
if (partname && partname[0] != '\0')
if (partname)
spec.attribute("oiio:subimagename", partname);
}

Expand Down

0 comments on commit fab3dc2

Please sign in to comment.