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

Fixed indentation #8623

Merged
merged 1 commit into from
Dec 26, 2024
Merged

Fixed indentation #8623

merged 1 commit into from
Dec 26, 2024

Conversation

radarhere
Copy link
Member

@radarhere radarhere commented Dec 26, 2024

Currently, the *_ALLOW_THREADS macros lead to odd indentation.

Pillow/src/_imagingcms.c

Lines 349 to 367 in 0e3f51d

Py_BEGIN_ALLOW_THREADS
// transform color channels only
for (i = 0; i < im->ysize; i++) {
cmsDoTransform(hTransform, im->image[i], imOut->image[i], im->xsize);
}
// lcms by default does nothing to the auxiliary channels leaving those
// unchanged. To do "the right thing" here, i.e. maintain identical results
// with and without inPlace, we replicate those channels to the output.
//
// As of lcms 2.8, a new cmsFLAGS_COPY_ALPHA flag is introduced which would
// do the same thing automagically. Unfortunately, lcms2.8 is not yet widely
// enough available on all platforms, so we polyfill it here for now.
pyCMScopyAux(hTransform, imOut, im);
Py_END_ALLOW_THREADS
return 0;

This PR consistently adds a semicolon after them to fix this.

@hugovk hugovk merged commit 6e66166 into python-pillow:main Dec 26, 2024
49 of 50 checks passed
@radarhere radarhere deleted the threads branch December 26, 2024 23:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants