Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

don't index empty array in testMultiPartSharedAttributes #443

Merged
merged 2 commits into from Jul 18, 2019

Conversation

peterhillman
Copy link
Contributor

Fix for #377

@@ -152,7 +152,7 @@ testMultiPartOutputFileForExpectedFailure (const vector<Header> & headers,
try
{
remove(fn.c_str());
MultiPartOutputFile file(fn.c_str(), &headers[0],headers.size());
MultiPartOutputFile file(fn.c_str(), (headers.size()>0 ? &headers[0] : NULL) , headers.size() );
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wouldn't header.data() be a more proper way of accessing the data?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it would, but is vector::data() available in all C++ versions that are supported by OpenEXR?

@cary-ilm
Copy link
Member

cary-ilm commented Jul 16, 2019 via email

Copy link
Contributor

@kdt3rd kdt3rd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM w/ .data()

@peterhillman peterhillman merged commit 42665b5 into AcademySoftwareFoundation:master Jul 18, 2019
@cary-ilm cary-ilm added this to the v2.4.0 milestone Aug 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants