Make WordPress Core

Ticket #24700: wordpress-permission.patch

File wordpress-permission.patch, 566 bytes (added by dennisjac, 11 years ago)

patch to fix overly restrictive check for plugin installation method

  • wp-admin/includes/file.php

    diff -ruN wordpress.orig/wp-admin/includes/file.php wordpress/wp-admin/includes/file.php
    old new  
    864864                $temp_file_name = $context . 'temp-write-test-' . time();
    865865                $temp_handle = @fopen($temp_file_name, 'w');
    866866                if ( $temp_handle ) {
    867                         if ( getmyuid() == @fileowner($temp_file_name) )
    868                                 $method = 'direct';
     867                        $method = 'direct';
    869868                        @fclose($temp_handle);
    870869                        @unlink($temp_file_name);
    871870                }