WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/09/2010 06:02:54 PM (9 years ago)
Author:
nacin
Message:

Always exit after wp_redirect. props filosofo, fixes #15518.

File:
1 edited

Legend:

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

    r16412 r16847  
    179179        wp_die(__('You are not allowed to import.'));
    180180
    181     if ( validate_file($importer) )
     181    if ( validate_file($importer) ) {
    182182        wp_redirect( admin_url( 'import.php?invalid=' . $importer ) );
     183        exit;
     184    }
    183185
    184186    // Allow plugins to define importers as well
    185187    if ( !isset($wp_importers) || !isset($wp_importers[$importer]) || ! is_callable($wp_importers[$importer][2])) {
    186         if (! file_exists(ABSPATH . "wp-admin/import/$importer.php"))
     188        if (! file_exists(ABSPATH . "wp-admin/import/$importer.php")) {
    187189            wp_redirect( admin_url( 'import.php?invalid=' . $importer ) );
     190            exit;
     191        }
    188192        include(ABSPATH . "wp-admin/import/$importer.php");
    189193    }
Note: See TracChangeset for help on using the changeset viewer.