Skip to content
This repository has been archived by the owner on Jun 1, 2024. It is now read-only.

Commit

Permalink
Fix Pillow memory leak? python-pillow/Pillow#2019 (comment)
Browse files Browse the repository at this point in the history
  • Loading branch information
karolyi committed May 3, 2020
1 parent 00881ea commit 4c46504
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions backend/forum/cdn/views/imager_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ def _get_thumbnail_path(
temp_path = Path(new_absolute_path).parent.joinpath(
f'temp-{new_absolute_path.name}')
image.save(fp=temp_path)
image.close()
temp_path.rename(new_absolute_path)
return new_absolute_path

Expand Down

0 comments on commit 4c46504

Please sign in to comment.