From cfb9a67baa31c0cc47b42824b7942b709ed86ffd Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 10 Oct 2024 07:44:58 +0530 Subject: [PATCH] ... --- src/calibre/srv/legacy.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/calibre/srv/legacy.py b/src/calibre/srv/legacy.py index 30815cc28b..986a25470c 100644 --- a/src/calibre/srv/legacy.py +++ b/src/calibre/srv/legacy.py @@ -285,6 +285,8 @@ def legacy_get(ctx, rd, what, book_id, library_id, filename): ua = rd.inheaders.get('User-Agent', '') is_old_kindle = 'Kindle/3' in ua ans = get(ctx, rd, what, book_id, library_id) - if is_old_kindle: # Content-Disposition causes downloads to fail when the filename has non-ascii chars in it + if is_old_kindle: + # Content-Disposition causes downloads to fail when the filename has non-ascii chars in it + # https://www.mobileread.com/forums/showthread.php?t=364015 rd.outheaders.pop('Content-Disposition', '') return ans