[wp-trac] [WordPress Trac] #39875: PDF previews overwrite existing images with the same name.
WordPress Trac
noreply at wordpress.org
Mon Feb 27 15:38:33 UTC 2017
#39875: PDF previews overwrite existing images with the same name.
-------------------------------------+------------------------
Reporter: gitlost | Owner: joemcgill
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 4.7.3
Component: Media | Version: 4.7
Severity: normal | Resolution: fixed
Keywords: has-patch needs-testing | Focuses:
-------------------------------------+------------------------
Changes (by joemcgill):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"40130"]:
{{{
#!CommitTicketReference repository="" revision="40130"
Media: Keep PDF previews from overwriting files.
Since support for PDF previews were added in [38949], it's possible
that the generated image file could overwrite an existing image file
with the same name. This uses `wp_unique_filename()` to avoid this
issue and adds a '-pdf' identifier on the end of filenames.
Props gitlost, derosj, mikeschroder, joemcgill.
Fixes #39875. See #31050.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/39875#comment:21>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list