diff --git a/wp-admin/includes/file.php b/wp-admin/includes/file.php index ddee18c687..ccd1a2e240 100644 --- a/wp-admin/includes/file.php +++ b/wp-admin/includes/file.php @@ -624,7 +624,7 @@ function wp_tempnam( $filename = '', $dir = '' ) { } if ( empty( $filename ) || '.' == $filename || '/' == $filename || '\\' == $filename ) { - $filename = time(); + $filename = uniqid(); } // Use the basename of the given file without the extension as the name for the temporary directory @@ -1466,7 +1466,7 @@ function get_filesystem_method( $args = array(), $context = '', $allow_relaxed_f if ( ! $method ) { - $temp_file_name = $context . 'temp-write-test-' . time(); + $temp_file_name = $context . 'temp-write-test-' . str_replace( '.', '-', uniqid( '', true ) ); $temp_handle = @fopen($temp_file_name, 'w'); if ( $temp_handle ) { diff --git a/wp-includes/version.php b/wp-includes/version.php index 07776387d3..e6bf0ec256 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '5.0-alpha-42222'; +$wp_version = '5.0-alpha-42224'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.