Make WordPress Core

Changeset 3103


Ignore:
Timestamp:
11/16/2005 03:27:22 AM (20 years ago)
Author:
ryan
Message:

Make sure plugins and themes are readable. Props Mike Little. fixes #1502

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-functions.php

    r3099 r3103  
    14501450
    14511451    foreach ($plugin_files as $plugin_file) {
     1452        if ( !is_readable("$plugin_root/$plugin_file"))
     1453            continue;
     1454
    14521455        $plugin_data = get_plugin_data("$plugin_root/$plugin_file");
    14531456
  • trunk/wp-includes/functions.php

    r3102 r3103  
    16871687
    16881688    foreach($theme_files as $theme_file) {
     1689        if ( ! is_readable("$theme_root/$theme_file") ) {
     1690            $wp_broken_themes[$theme_file] = array('Name' => $theme_file, 'Title' => $theme_file, 'Description' => __('File not readable.'));
     1691            continue;
     1692        }
     1693
    16891694        $theme_data = get_theme_data("$theme_root/$theme_file");
    16901695
Note: See TracChangeset for help on using the changeset viewer.