From 39b144baddca433b9aa28f99e595ffcc191c0bee Mon Sep 17 00:00:00 2001 From: Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> Date: Fri, 4 Apr 2025 09:52:22 +0200 Subject: [5.1.x] Fixed #36298 -- Truncated the overwritten file content in file_move_safe(). Regression in 58cd4902a71a3695dd6c21dc957f59c333db364c. Thanks Baptiste Mispelon for the report. Backport of 8ad3e80e88201f4c557f6fa79fcfc0f8a0961830 from main. --- docs/releases/4.2.21.txt | 15 +++++++++++++++ docs/releases/5.1.9.txt | 15 +++++++++++++++ docs/releases/index.txt | 2 ++ 3 files changed, 32 insertions(+) create mode 100644 docs/releases/4.2.21.txt create mode 100644 docs/releases/5.1.9.txt (limited to 'docs') diff --git a/docs/releases/4.2.21.txt b/docs/releases/4.2.21.txt new file mode 100644 index 0000000000..36e24df12f --- /dev/null +++ b/docs/releases/4.2.21.txt @@ -0,0 +1,15 @@ +=========================== +Django 4.2.21 release notes +=========================== + +*Expected May 7, 2025* + +Django 4.2.21 fixes a data loss bug in 4.2.20. + +Bugfixes +======== + +* Fixed a data corruption possibility in ``file_move_safe()`` when + ``allow_overwrite=True``, where leftover content from a previously larger + file could remain after overwriting with a smaller one due to lack of + truncation (:ticket:`36298`). diff --git a/docs/releases/5.1.9.txt b/docs/releases/5.1.9.txt new file mode 100644 index 0000000000..6847aa9a2c --- /dev/null +++ b/docs/releases/5.1.9.txt @@ -0,0 +1,15 @@ +========================== +Django 5.1.9 release notes +========================== + +*Expected May 7, 2025* + +Django 5.1.9 fixes a data loss bug in 5.1.8. + +Bugfixes +======== + +* Fixed a data corruption possibility in ``file_move_safe()`` when + ``allow_overwrite=True``, where leftover content from a previously larger + file could remain after overwriting with a smaller one due to lack of + truncation (:ticket:`36298`). diff --git a/docs/releases/index.txt b/docs/releases/index.txt index 3f7b52d86f..9c91a0a6f6 100644 --- a/docs/releases/index.txt +++ b/docs/releases/index.txt @@ -25,6 +25,7 @@ versions of the documentation contain the release notes for any later releases. .. toctree:: :maxdepth: 1 + 5.1.9 5.1.8 5.1.7 5.1.6 @@ -62,6 +63,7 @@ versions of the documentation contain the release notes for any later releases. .. toctree:: :maxdepth: 1 + 4.2.21 4.2.20 4.2.19 4.2.18 -- cgit v1.3