Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #38083


Ignore:
Timestamp:
09/18/2016 01:18:20 AM (8 years ago)
Author:
SergeyBiryukov
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #38083

    • Property Component changed from General to Upgrade/Install
    • Property Milestone changed from Awaiting Review to 4.6.2
  • Ticket #38083 – Description

    initial v1  
    1 This change - https://build.trac.wordpress.org/changeset/38466 in WP 4.6.1 broke my plugin - https://plugins.svn.wordpress.org/upload-larger-plugins/tags/1.4/ .
     1This change - [38525] in WP 4.6.1 broke my plugin - https://plugins.svn.wordpress.org/upload-larger-plugins/tags/1.4/ .
    22
    33I was using the upgrader_pre_download filter to over-ride the package (i.e. zip) that gets installed. However, the added check now makes that method impossible, because it applies a new consistency check. And specifically, realpath() returns false if the file in the parameter does not exist, causing the check to fail, and wp_die() to be called. If the two paths are compared without realpath() being called, the check would pass (i.e. the second string is indeed a substring of the first)... but because realpath() is introducing an implicit "file must exist" condition, it now fails.