Ticket #40875: 40875.diff
File 40875.diff, 1.3 KB (added by , 7 years ago) |
---|
-
wp-includes/default-constants.php
26 26 define( 'MB_IN_BYTES', 1024 * KB_IN_BYTES ); 27 27 define( 'GB_IN_BYTES', 1024 * MB_IN_BYTES ); 28 28 define( 'TB_IN_BYTES', 1024 * GB_IN_BYTES ); 29 define( 'PB_IN_BYTES', 1024 * TB_IN_BYTES ); 29 30 /**#@-*/ 30 31 31 32 $current_limit = @ini_get( 'memory_limit' ); -
wp-includes/functions.php
236 236 * 237 237 * It is easier to read 1 KB than 1024 bytes and 1 MB than 1048576 bytes. Converts 238 238 * number of bytes to human readable number by taking the number of that unit 239 * that the bytes will go into it. Supports TB value.239 * that the bytes will go into it. Supports TB and PB value. 240 240 * 241 241 * Please note that integers in PHP are limited to 32 bits, unless they are on 242 242 * 64 bit architecture, then they have 64 bit size. If you need to place the … … 253 253 */ 254 254 function size_format( $bytes, $decimals = 0 ) { 255 255 $quant = array( 256 'PB' => PB_IN_BYTES, 256 257 'TB' => TB_IN_BYTES, 257 258 'GB' => GB_IN_BYTES, 258 259 'MB' => MB_IN_BYTES,