Make WordPress Core

Opened 8 years ago

Closed 8 years ago

#36943 closed defect (bug) (fixed)

get_contents doesn't unlink tempfile on error

Reported by: ruudjoyo's profile ruud@… Owned by: dd32's profile dd32
Milestone: 4.6 Priority: normal
Severity: normal Version:
Component: Filesystem API Keywords: has-patch
Focuses: Cc:

Description

Similar to #34772 and #36941, #36942, the get_contents method is also lacking the unlinking of the tempfile on error.

Attachments (1)

class-wp-filesystem-ftpsockets.patch (1.4 KB) - added by ruud@… 8 years ago.
added unlink to error situation

Download all attachments as: .zip

Change History (5)

@ruud@…
8 years ago

added unlink to error situation

#1 @ruud@…
8 years ago

  • Keywords has-patch dev-feedback added

#2 @ocean90
8 years ago

  • Version trunk deleted

#3 @dd32
8 years ago

  • Keywords dev-feedback removed
  • Milestone changed from Awaiting Review to 4.6
  • Owner set to dd32
  • Status changed from new to accepted

#4 @ocean90
8 years ago

  • Resolution set to fixed
  • Status changed from accepted to closed

In 38094:

Filesystem API: Cleanup temporary file when the temporary file couldn't be opened.

Props ruud@joyo.
See #34772.
Fixes #36942, #36943.

Note: See TracTickets for help on using tickets.