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

Fix image capture indices always starting from 1 #2656

Merged
merged 1 commit into from Jul 1, 2023

Conversation

johnnovak
Copy link
Member

@johnnovak johnnovak commented Jul 1, 2023

A last-minute improvement to the capture PR to create the capture directory on-demand (lazily) introduced a regression: the image capture indices now always start from 1, potentially overwriting existing images. This was a result of the image capturers running asynchronously in separate threads combined with the lazy/deferred capture directory creation and highest index lookup approach.

This is the fix for that, plus also for a potential race condition when determining the current highest capture indices.

@johnnovak johnnovak self-assigned this Jul 1, 2023
@johnnovak johnnovak added the regression We broke something 😊 label Jul 1, 2023
@johnnovak johnnovak force-pushed the jn/fix-capture-index-generation branch from cd2e0d2 to 429f7b5 Compare July 1, 2023 07:18
Copy link
Collaborator

@FeralChild64 FeralChild64 left a comment

Choose a reason for hiding this comment

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

Looks OK.

BTW - funny thing, I just wanted to report this bug, and the fix is already available :)

@johnnovak
Copy link
Member Author

Thanks for the review @FeralChild64

@johnnovak johnnovak merged commit 723a541 into main Jul 1, 2023
52 checks passed
@johnnovak johnnovak deleted the jn/fix-capture-index-generation branch July 8, 2023 00:27
@johnnovak johnnovak added the video Graphics and video related issues label Dec 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
regression We broke something 😊 video Graphics and video related issues
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

2 participants