WordPress.org

Make WordPress Core


Ignore:
Location:
branches/4.4/src
Files:
19 edited

Legend:

Unmodified
Added
Removed
  • branches/4.4/src/readme.html

    r36206 r36463  
    1010<h1 id="logo">
    1111    <a href="https://wordpress.org/"><img alt="WordPress" src="wp-admin/images/wordpress-logo.png" /></a>
    12     <br /> Version 4.4.1
     12    <br /> Version 4.4.2
    1313</h1>
    1414<p style="text-align: center">Semantic Personal Publishing Platform</p>
  • branches/4.4/src/wp-admin/about.php

    r36206 r36463  
    5050
    5151        <div class="changelog point-releases">
    52             <h3><?php echo _n( 'Maintenance and Security Release', 'Maintenance and Security Releases', 1 ); ?></h3>
     52            <h3><?php echo _n( 'Maintenance and Security Release', 'Maintenance and Security Releases', 2 ); ?></h3>
     53            <p><?php printf( _n( '<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bug.',
     54                '<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bugs.', 17 ), '4.4.2', number_format_i18n( 17 ) ); ?>
     55                <?php printf( __( 'For more information, see <a href="%s">the release notes</a>.' ), 'https://codex.wordpress.org/Version_4.4.2' ); ?>
     56            </p>
    5357            <p><?php printf( _n( '<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bug.',
    5458                '<strong>Version %1$s</strong> addressed some security issues and fixed %2$s bugs.', 52 ), '4.4.1', number_format_i18n( 52 ) ); ?>
  • branches/4.4/src/wp-admin/includes/image.php

    r36206 r36463  
    409409    }
    410410
    411     foreach ( $meta as &$value ) {
    412         if ( is_string( $value ) ) {
    413             $value = wp_kses_post( $value );
    414         }
    415     }
     411    foreach ( $meta['keywords'] as $key => $keyword ) {
     412        if ( ! seems_utf8( $keyword ) ) {
     413            $meta['keywords'][ $key ] = utf8_encode( $keyword );
     414        }
     415    }
     416
     417    $meta = wp_kses_post_deep( $meta );
    416418
    417419    /**
  • branches/4.4/src/wp-admin/js/inline-edit-tax.js

    r36206 r36463  
    138138            }
    139139        );
     140        // Prevent submitting the form when pressing Enter on a focused field.
     141        return false;
    140142    },
    141143
  • branches/4.4/src/wp-admin/widgets.php

    r36206 r36463  
    407407            $wrap_class .= ' ' . $registered_sidebar['class'];
    408408
     409        $is_inactive_widgets = 'wp_inactive_widgets' == $registered_sidebar['id'];
    409410        ?>
    410411        <div class="<?php echo esc_attr( $wrap_class ); ?>">
    411412            <div class="widget-holder inactive">
    412413                <?php wp_list_widget_controls( $registered_sidebar['id'], $registered_sidebar['name'] ); ?>
     414
     415                <?php if ( $is_inactive_widgets ) { ?>
    413416                <div class="remove-inactive-widgets">
    414417                    <form action="" method="post">
     
    428431                    </form>
    429432                </div>
     433                <?php } ?>
    430434            </div>
     435            <?php if ( $is_inactive_widgets ) { ?>
    431436            <p class="description"><?php _e( 'This will clear all items from the inactive widgets list. You will not be able to restore any customizations.' ); ?></p>
     437            <?php } ?>
    432438        </div>
    433439        <?php
  • branches/4.4/src/wp-includes/class-wp-comment-query.php

    r36206 r36463  
    5959        'limits'  => '',
    6060    );
     61
     62    /**
     63     * SQL WHERE clause.
     64     *
     65     * Stored after the 'comments_clauses' filter is run on the compiled WHERE sub-clauses.
     66     *
     67     * @since 4.4.2
     68     * @access protected
     69     * @var string
     70     */
     71    protected $filtered_where_clause;
    6172
    6273    /**
     
    748759                // $field_value may be an array.
    749760                $esses = array_fill( 0, count( (array) $field_value ), '%s' );
    750                 $this->sql_clauses['where']['post_fields'] = $wpdb->prepare( " {$wpdb->posts}.{$field_name} IN (" . implode( ',', $esses ) . ')', $field_value );
     761                $this->sql_clauses['where'][ $field_name ] = $wpdb->prepare( " {$wpdb->posts}.{$field_name} IN (" . implode( ',', $esses ) . ')', $field_value );
    751762            }
    752763        }
     
    817828        $groupby = isset( $clauses[ 'groupby' ] ) ? $clauses[ 'groupby' ] : '';
    818829
     830        $this->filtered_where_clause = $where;
     831
    819832        if ( $where ) {
    820833            $where = 'WHERE ' . $where;
     
    868881        );
    869882
    870         $where_clauses = $this->sql_clauses['where'];
    871         unset(
    872             $where_clauses['parent'],
    873             $where_clauses['parent__in'],
    874             $where_clauses['parent__not_in']
    875         );
     883        /*
     884         * The WHERE clause for the descendant query is the same as for the top-level
     885         * query, minus the `parent`, `parent__in`, and `parent__not_in` sub-clauses.
     886         */
     887        $_where = $this->filtered_where_clause;
     888        $exclude_keys = array( 'parent', 'parent__in', 'parent__not_in' );
     889        foreach ( $exclude_keys as $exclude_key ) {
     890            if ( isset( $this->sql_clauses['where'][ $exclude_key ] ) ) {
     891                $clause = $this->sql_clauses['where'][ $exclude_key ];
     892
     893                // Strip the clause as well as any adjacent ANDs.
     894                $pattern = '|(?:AND)?\s*' . $clause . '\s*(?:AND)?|';
     895                $_where_parts = preg_split( $pattern, $_where );
     896
     897                // Remove empties.
     898                $_where_parts = array_filter( array_map( 'trim', $_where_parts ) );
     899
     900                // Reassemble with an AND.
     901                $_where = implode( ' AND ', $_where_parts );
     902            }
     903        }
    876904
    877905        // Fetch an entire level of the descendant tree at a time.
     
    883911            }
    884912
    885             $where = 'WHERE ' . implode( ' AND ', $where_clauses ) . ' AND comment_parent IN (' . implode( ',', array_map( 'intval', $parent_ids ) ) . ')';
     913            $where = 'WHERE ' . $_where . ' AND comment_parent IN (' . implode( ',', array_map( 'intval', $parent_ids ) ) . ')';
    886914            $comment_ids = $wpdb->get_col( "{$this->sql_clauses['select']} {$this->sql_clauses['from']} {$where} {$this->sql_clauses['groupby']} ORDER BY comment_date_gmt ASC, comment_ID ASC" );
    887915
  • branches/4.4/src/wp-includes/class-wp-customize-manager.php

    r36206 r36463  
    15361536    public function get_return_url() {
    15371537        $referer = wp_get_referer();
     1538        $excluded_referer_basenames = array( 'customize.php', 'wp-login.php' );
     1539
    15381540        if ( $this->return_url ) {
    15391541            $return_url = $this->return_url;
    1540         } else if ( $referer && 'customize.php' !== basename( parse_url( $referer, PHP_URL_PATH ) ) ) {
     1542        } else if ( $referer && ! in_array( basename( parse_url( $referer, PHP_URL_PATH ) ), $excluded_referer_basenames, true ) ) {
    15411543            $return_url = $referer;
    15421544        } else if ( $this->preview_url ) {
  • branches/4.4/src/wp-includes/comment-template.php

    r36206 r36463  
    12861286        'status'  => 'approve',
    12871287        'post_id' => $post->ID,
    1288         'hierarchical' => 'threaded',
    12891288        'no_found_rows' => false,
    12901289        'update_comment_meta_cache' => false, // We lazy-load comment meta for performance.
    12911290    );
     1291
     1292    if ( get_option('thread_comments') ) {
     1293        $comment_args['hierarchical'] = 'threaded';
     1294    } else {
     1295        $comment_args['hierarchical'] = false;
     1296    }
    12921297
    12931298    if ( $user_ID ) {
     
    13181323                'orderby' => false,
    13191324                'post_id' => $post->ID,
    1320                 'parent'  => 0,
    13211325                'status'  => 'approve',
    13221326            );
     1327
     1328            if ( $comment_args['hierarchical'] ) {
     1329                $top_level_args['parent'] = 0;
     1330            }
    13231331
    13241332            if ( isset( $comment_args['include_unapproved'] ) ) {
     
    13361344
    13371345    // Trees must be flattened before they're passed to the walker.
    1338     $comments_flat = array();
    1339     foreach ( $_comments as $_comment ) {
    1340         $comments_flat[]  = $_comment;
    1341         $comment_children = $_comment->get_children( array(
    1342             'format' => 'flat',
    1343             'status' => $comment_args['status'],
    1344             'orderby' => $comment_args['orderby']
    1345         ) );
    1346 
    1347         foreach ( $comment_children as $comment_child ) {
    1348             $comments_flat[] = $comment_child;
     1346    if ( $comment_args['hierarchical'] ) {
     1347        $comments_flat = array();
     1348        foreach ( $_comments as $_comment ) {
     1349            $comments_flat[]  = $_comment;
     1350            $comment_children = $_comment->get_children( array(
     1351                'format' => 'flat',
     1352                'status' => $comment_args['status'],
     1353                'orderby' => $comment_args['orderby']
     1354            ) );
     1355
     1356            foreach ( $comment_children as $comment_child ) {
     1357                $comments_flat[] = $comment_child;
     1358            }
    13491359        }
     1360    } else {
     1361        $comments_flat = $_comments;
    13501362    }
    13511363
     
    19261938    $r = apply_filters( 'wp_list_comments_args', $r );
    19271939
    1928     /*
    1929      * If 'page' or 'per_page' has been passed, and does not match what's in $wp_query,
    1930      * perform a separate comment query and allow Walker_Comment to paginate.
    1931      */
    1932     if ( is_singular() && ( $r['page'] || $r['per_page'] ) ) {
    1933         $current_cpage = get_query_var( 'cpage' );
    1934         if ( ! $current_cpage ) {
    1935             $current_cpage = 'newest' === get_option( 'default_comments_page' ) ? 1 : $wp_query->max_num_comment_pages;
    1936         }
    1937 
    1938         $current_per_page = get_query_var( 'comments_per_page' );
    1939         if ( $r['page'] != $current_cpage || $r['per_page'] != $current_per_page ) {
    1940             $comments = get_comments( array(
    1941                 'post_id' => get_queried_object_id(),
    1942                 'orderby' => 'comment_date_gmt',
    1943                 'order' => 'ASC',
    1944                 'status' => 'all',
    1945             ) );
    1946         }
    1947     }
    1948 
    19491940    // Figure out what comments we'll be looping through ($_comments)
    19501941    if ( null !== $comments ) {
     
    19611952        }
    19621953    } else {
    1963         if ( empty($wp_query->comments) )
    1964             return;
    1965         if ( 'all' != $r['type'] ) {
    1966             if ( empty($wp_query->comments_by_type) )
    1967                 $wp_query->comments_by_type = separate_comments($wp_query->comments);
    1968             if ( empty($wp_query->comments_by_type[$r['type']]) )
     1954        /*
     1955         * If 'page' or 'per_page' has been passed, and does not match what's in $wp_query,
     1956         * perform a separate comment query and allow Walker_Comment to paginate.
     1957         */
     1958        if ( $r['page'] || $r['per_page'] ) {
     1959            $current_cpage = get_query_var( 'cpage' );
     1960            if ( ! $current_cpage ) {
     1961                $current_cpage = 'newest' === get_option( 'default_comments_page' ) ? 1 : $wp_query->max_num_comment_pages;
     1962            }
     1963
     1964            $current_per_page = get_query_var( 'comments_per_page' );
     1965            if ( $r['page'] != $current_cpage || $r['per_page'] != $current_per_page ) {
     1966
     1967                $comments = get_comments( array(
     1968                    'post_id' => get_the_ID(),
     1969                    'orderby' => 'comment_date_gmt',
     1970                    'order' => 'ASC',
     1971                    'status' => 'all',
     1972                ) );
     1973
     1974                if ( 'all' != $r['type'] ) {
     1975                    $comments_by_type = separate_comments( $comments );
     1976                    if ( empty( $comments_by_type[ $r['type'] ] ) ) {
     1977                        return;
     1978                    }
     1979
     1980                    $_comments = $comments_by_type[ $r['type'] ];
     1981                } else {
     1982                    $_comments = $comments;
     1983                }
     1984            }
     1985
     1986        // Otherwise, fall back on the comments from `$wp_query->comments`.
     1987        } else {
     1988            if ( empty($wp_query->comments) )
    19691989                return;
    1970             $_comments = $wp_query->comments_by_type[$r['type']];
    1971         } else {
    1972             $_comments = $wp_query->comments;
    1973         }
    1974 
    1975         // Pagination is already handled by `WP_Comment_Query`, so we tell Walker not to bother.
    1976         if ( $wp_query->max_num_comment_pages ) {
    1977             $default_comments_page = get_option( 'default_comments_page' );
    1978             $cpage = get_query_var( 'cpage' );
    1979             if ( 'newest' === $default_comments_page ) {
    1980                 $r['cpage'] = $cpage;
    1981 
    1982             // When first page shows oldest comments, post permalink is the same as the comment permalink.
    1983             } elseif ( $cpage == 1 ) {
    1984                 $r['cpage'] = '';
     1990            if ( 'all' != $r['type'] ) {
     1991                if ( empty($wp_query->comments_by_type) )
     1992                    $wp_query->comments_by_type = separate_comments($wp_query->comments);
     1993                if ( empty($wp_query->comments_by_type[$r['type']]) )
     1994                    return;
     1995                $_comments = $wp_query->comments_by_type[$r['type']];
    19851996            } else {
    1986                 $r['cpage'] = $cpage;
     1997                $_comments = $wp_query->comments;
    19871998            }
    19881999
    1989             $r['page'] = 0;
    1990             $r['per_page'] = 0;
     2000            if ( $wp_query->max_num_comment_pages ) {
     2001                $default_comments_page = get_option( 'default_comments_page' );
     2002                $cpage = get_query_var( 'cpage' );
     2003                if ( 'newest' === $default_comments_page ) {
     2004                    $r['cpage'] = $cpage;
     2005
     2006                /*
     2007                 * When first page shows oldest comments, post permalink is the same as
     2008                 * the comment permalink.
     2009                 */
     2010                } elseif ( $cpage == 1 ) {
     2011                    $r['cpage'] = '';
     2012                } else {
     2013                    $r['cpage'] = $cpage;
     2014                }
     2015
     2016                $r['page'] = 0;
     2017                $r['per_page'] = 0;
     2018            }
    19912019        }
    19922020    }
  • branches/4.4/src/wp-includes/formatting.php

    r36206 r36463  
    45354535         * @param string The emoji base URL.
    45364536         */
    4537         'baseUrl' => apply_filters( 'emoji_url', set_url_scheme( '//s.w.org/images/core/emoji/72x72/' ) ),
     4537        'baseUrl' => apply_filters( 'emoji_url', 'https://s.w.org/images/core/emoji/72x72/' ),
    45384538
    45394539        /**
     
    46474647
    46484648    /** This filter is documented in wp-includes/formatting.php */
    4649     $cdn_url = apply_filters( 'emoji_url', set_url_scheme( '//s.w.org/images/core/emoji/72x72/' ) );
     4649    $cdn_url = apply_filters( 'emoji_url', 'https://s.w.org/images/core/emoji/72x72/' );
    46504650
    46514651    /** This filter is documented in wp-includes/formatting.php */
  • branches/4.4/src/wp-includes/http.php

    r36206 r36463  
    537537        if ( $ip ) {
    538538            $parts = array_map( 'intval', explode( '.', $ip ) );
    539             if ( 127 === $parts[0] || 10 === $parts[0]
     539            if ( 127 === $parts[0] || 10 === $parts[0] || 0 === $parts[0]
    540540                || ( 172 === $parts[0] && 16 <= $parts[1] && 31 >= $parts[1] )
    541541                || ( 192 === $parts[0] && 168 === $parts[1] )
  • branches/4.4/src/wp-includes/js/wp-emoji-loader.js

    r36206 r36463  
    1414        var canvas = document.createElement( 'canvas' ),
    1515            context = canvas.getContext && canvas.getContext( '2d' ),
     16            stringFromCharCode = String.fromCharCode,
    1617            tone;
    1718
     
    3839             * to a larger image (4-5KB data URL).
    3940             */
    40             context.fillText( String.fromCharCode( 55356, 56806, 55356, 56826 ), 0, 0 );
     41            context.fillText( stringFromCharCode( 55356, 56806, 55356, 56826 ), 0, 0 );
    4142            return canvas.toDataURL().length > 3000;
    4243        } else if ( 'diversity' === type ) {
     
    4647             * compares if the emoji rendering has changed.
    4748             */
    48             context.fillText( String.fromCharCode( 55356, 57221 ), 0, 0 );
     49            context.fillText( stringFromCharCode( 55356, 57221 ), 0, 0 );
    4950            tone = context.getImageData( 16, 16, 1, 1 ).data.toString();
    50             context.fillText( String.fromCharCode( 55356, 57221, 55356, 57343 ), 0, 0 );
     51            context.fillText( stringFromCharCode( 55356, 57221, 55356, 57343 ), 0, 0 );
    5152            // Chrome has issues comparing arrays, so we compare it as a  string, instead.
    5253            return tone !== context.getImageData( 16, 16, 1, 1 ).data.toString();
     
    5859                 * as an empty square, so the center pixel will be blank.
    5960                 */
    60                 context.fillText( String.fromCharCode( 55357, 56835 ), 0, 0 );
     61                context.fillText( stringFromCharCode( 55357, 56835 ), 0, 0 );
    6162            } else {
    6263                /*
     
    6465                 * that the Unicode Consortium have made in years: the burrito.
    6566                 */
    66                 context.fillText( String.fromCharCode( 55356, 57135 ), 0, 0 );
     67                context.fillText( stringFromCharCode( 55356, 57135 ), 0, 0 );
    6768            }
    6869            return context.getImageData( 16, 16, 1, 1 ).data[0] !== 0;
  • branches/4.4/src/wp-includes/kses.php

    r36206 r36463  
    15821582
    15831583/**
     1584 * Navigates through an array, object, or scalar, and sanitizes content for
     1585 * allowed HTML tags for post content.
     1586 *
     1587 * @since 4.4.2
     1588 *
     1589 * @param mixed $value The array or string to filter.
     1590 * @return mixed $value The filtered content.
     1591 */
     1592function wp_kses_post_deep( $data ) {
     1593    return map_deep( $data, 'wp_kses_post' );
     1594}
     1595
     1596/**
    15841597 * Strips all of the HTML in the content.
    15851598 *
  • branches/4.4/src/wp-includes/load.php

    r36206 r36463  
    474474
    475475    if ( function_exists( 'wp_cache_add_global_groups' ) ) {
    476         wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache' ) );
     476        wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache', 'networks' ) );
    477477        wp_cache_add_non_persistent_groups( array( 'comment', 'counts', 'plugins' ) );
    478478    }
  • branches/4.4/src/wp-includes/ms-blogs.php

    r36206 r36463  
    655655                wp_cache_add_global_groups( $global_groups );
    656656            } else {
    657                 wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache' ) );
     657                wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache', 'networks' ) );
    658658            }
    659659            wp_cache_add_non_persistent_groups( array( 'comment', 'counts', 'plugins' ) );
     
    726726                wp_cache_add_global_groups( $global_groups );
    727727            } else {
    728                 wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache' ) );
     728                wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'site-lookup', 'blog-lookup', 'blog-details', 'rss', 'global-posts', 'blog-id-cache', 'networks' ) );
    729729            }
    730730            wp_cache_add_non_persistent_groups( array( 'comment', 'counts', 'plugins' ) );
  • branches/4.4/src/wp-includes/pluggable.php

    r36206 r36463  
    13341334    $test = ( $cut = strpos($location, '?') ) ? substr( $location, 0, $cut ) : $location;
    13351335
    1336     $lp  = parse_url($test);
     1336    // @-operator is used to prevent possible warnings in PHP < 5.3.3.
     1337    $lp = @parse_url($test);
    13371338
    13381339    // Give up if malformed URL
     
    13441345        return $default;
    13451346
    1346     // Reject if scheme is set but host is not. This catches urls like https:host.com for which parse_url does not set the host field.
    1347     if ( isset($lp['scheme'])  && !isset($lp['host']) )
     1347    // Reject if certain components are set but host is not. This catches urls like https:host.com for which parse_url does not set the host field.
     1348    if ( ! isset( $lp['host'] ) && ( isset( $lp['scheme'] ) || isset( $lp['user'] ) || isset( $lp['pass'] ) || isset( $lp['port'] ) ) ) {
    13481349        return $default;
     1350    }
     1351
     1352    // Reject malformed components parse_url() can return on odd inputs
     1353    foreach ( array( 'user', 'pass', 'host' ) as $component ) {
     1354        if ( isset( $lp[ $component ] ) && strpbrk( $lp[ $component ], ':/?#@' ) ) {
     1355            return $default;
     1356        }
     1357    }
    13491358
    13501359    $wpp = parse_url(home_url());
  • branches/4.4/src/wp-includes/query.php

    r36206 r36463  
    23012301            }
    23022302
    2303             $search_orderby = '(CASE ';
     2303            $search_orderby = '';
    23042304
    23052305            // sentence match in 'post_title'
     
    23222322                $search_orderby .= $wpdb->prepare( "WHEN $wpdb->posts.post_content LIKE %s THEN 4 ", $like );
    23232323            }
    2324             $search_orderby .= 'ELSE 5 END)';
     2324
     2325            if ( $search_orderby ) {
     2326                $search_orderby = '(CASE ' . $search_orderby . 'ELSE 5 END)';
     2327            }
    23252328        } else {
    23262329            // single word or sentence search
     
    49824985 * @global WP_Query   $wp_query   Global WP_Query instance.
    49834986 * @global wpdb       $wpdb       WordPress database abstraction object.
    4984  * @global WP_Rewrite $wp_rewrite WordPress rewrite component.
    49854987 */
    49864988function wp_old_slug_redirect() {
    4987     global $wp_query, $wp_rewrite;
    4988 
    4989     if ( get_queried_object() ) {
    4990         return;
    4991     }
    4992 
    4993     if ( '' !== $wp_query->query_vars['name'] ) :
     4989    global $wp_query;
     4990
     4991    if ( is_404() && '' !== $wp_query->query_vars['name'] ) :
    49944992        global $wpdb;
    49954993
     
    50335031        $link = get_permalink( $id );
    50345032
    5035         if ( is_feed() ) {
    5036             $link = user_trailingslashit( trailingslashit( $link ) . 'feed' );
    5037         } elseif ( isset( $GLOBALS['wp_query']->query_vars['paged'] ) && $GLOBALS['wp_query']->query_vars['paged'] > 1 ) {
     5033        if ( isset( $GLOBALS['wp_query']->query_vars['paged'] ) && $GLOBALS['wp_query']->query_vars['paged'] > 1 ) {
    50385034            $link = user_trailingslashit( trailingslashit( $link ) . 'page/' . $GLOBALS['wp_query']->query_vars['paged'] );
    50395035        } elseif( is_embed() ) {
    50405036            $link = user_trailingslashit( trailingslashit( $link ) . 'embed' );
    5041         } elseif ( is_404() ) {
    5042             // Add rewrite endpoints if necessary.
    5043             foreach ( $wp_rewrite->endpoints as $endpoint ) {
    5044                 if ( $endpoint[2] && false !== get_query_var( $endpoint[2], false ) ) {
    5045                     $link = user_trailingslashit( trailingslashit( $link ) . $endpoint[1] );
    5046                 }
    5047             }
    50485037        }
    50495038
  • branches/4.4/src/wp-includes/random_compat/random.php

    r36206 r36463  
    5757         * See ERRATA.md for our reasoning behind this particular order
    5858         */
    59         if (extension_loaded('libsodium')) {
     59        if (PHP_VERSION_ID >= 50300 && extension_loaded('libsodium') && function_exists('\\Sodium\\randombytes_buf')) {
    6060            // See random_bytes_libsodium.php
    6161            require_once $RandomCompatDIR.'/random_bytes_libsodium.php';
  • branches/4.4/src/wp-includes/taxonomy.php

    r36206 r36463  
    36473647    foreach ( (array) $terms as $term ) {
    36483648        // Create a copy in case the array was passed by reference.
    3649         $_term = $term;
     3649        $_term = clone $term;
    36503650
    36513651        // Object ID should not be cached.
  • branches/4.4/src/wp-includes/version.php

    r36206 r36463  
    55 * @global string $wp_version
    66 */
    7 $wp_version = '4.4.1-src';
     7$wp_version = '4.4.2-src';
    88
    99/**
Note: See TracChangeset for help on using the changeset viewer.