3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $start = strtotime(2014-01-02); $end = date('Y-m-d', strtotime($start. '+1 day')); echo $end; ?>
Output for 4.3.0 - 4.4.9, 5.1.0 - 7.1.0
1970-01-01
Output for 5.0.1 - 5.0.5
1388603459-11-02
Output for 5.0.0
1388603459-11-02*** Error in `/bin/php-5.0.0': free(): invalid next size (fast): 0x0000000002a86920 *** ======= Backtrace: ========= /usr/lib/libc.so.6(+0x6f364)[0x7f2709238364] /usr/lib/libc.so.6(+0x74d96)[0x7f270923dd96] /usr/lib/libc.so.6(+0x7557e)[0x7f270923e57e] /bin/php-5.0.0(shutdown_memory_manager+0x5f)[0x5b4faf] /bin/php-5.0.0(php_request_shutdown+0x1df)[0x592c5f] /bin/php-5.0.0(main+0x584)[0x43fc44] /usr/lib/libc.so.6(__libc_start_main+0xf0)[0x7f27091e9710] /bin/php-5.0.0[0x44067d] ======= Memory map: ======== 00400000-007c9000 r-xp 00000000 00:00 0 007c9000-009c9000 ---p 00000000 00:00 0 009c9000-009f8000 rwxp 00000000 00:00 0 00a00000-00a01000 rwxp 00000000 00:00 0 02992000-02aa5000 rwxp 00000000 00:00 0 [heap] 7f2704000000-7f2704021000 rwxp 00000000 00:00 0 7f2704021000-7f2708000000 ---p 00000000 00:00 0 7f270894c000-7f2708962000 r-xp 00000000 00:13 7782 /usr/lib/libgcc_s.so.1 7f2708962000-7f2708b61000 ---p 00016000 00:13 7782 /usr/lib/libgcc_s.so.1 7f2708b61000-7f2708b62000 rwxp 00015000 00:13 7782 /usr/lib/libgcc_s.so.1 7f2708b6f000-7f2708b7a000 r-xp 00000000 00:13 7901 /usr/lib/libnss_files-2.23.so 7f2708b7a000-7f2708d79000 ---p 0000b000 00:13 7901 /usr/lib/libnss_files-2.23.so 7f2708d79000-7f2708d7a000 r-xp 0000a000 00:13 7901 /usr/lib/libnss_files-2.23.so 7f2708d7a000-7f2708d7b000 rwxp 0000b000 00:13 7901 /usr/lib/libnss_files-2.23.so 7f2708d7b000-7f2708d85000 rwxp 00000000 00:00 0 7f2708d85000-7f2708d9d000 r-xp 00000000 00:13 7927 /usr/lib/libpthread-2.23.so 7f2708d9d000-7f2708f9c000 ---p 00018000 00:13 7927 /usr/lib/libpthread-2.23.so 7f2708f9c000-7f2708f9d000 r-xp 00017000 00:13 7927 /usr/lib/libpthread-2.23.so 7f2708f9d000-7f2708f9e000 rwxp 00018000 00:13 7927 /usr/lib/libpthread-2.23.so 7f2708f9e000-7f2708fa2000 rwxp 00000000 00:00 0 7f2708fa2000-7f2708fc7000 r-xp 00000000 00:13 7870 /usr/lib/liblzma.so.5.2.2 7f2708fc7000-7f27091c6000 ---p 00025000 00:13 7870 /usr/lib/liblzma.so.5.2.2 7f27091c6000-7f27091c7000 r-xp 00024000 00:13 7870 /usr/lib/liblzma.so.5.2.2 7f27091c7000-7f27091c8000 rwxp 00025000 00:13 7870 /usr/lib/liblzma.so.5.2.2 7f27091c8000-7f27091c9000 rwxp 00000000 00:00 0 7f27091c9000-7f2709361000 r-xp 00000000 00:13 7737 /usr/lib/libc-2.23.so 7f2709361000-7f2709560000 ---p 00198000 00:13 7737 /usr/lib/libc-2.23.so 7f2709560000-7f2709564000 r-xp 00197000 00:13 7737 /usr/lib/libc-2.23.so 7f2709564000-7f2709566000 rwxp 0019b000 00:13 7737 /usr/lib/libc-2.23.so 7f2709566000-7f270956a000 rwxp 00000000 00:00 0 7f270956a000-7f27096c8000 r-xp 00000000 00:13 8004 /usr/lib/libxml2.so.2.9.3 7f27096c8000-7f27098c7000 ---p 0015e000 00:13 8004 /usr/lib/libxml2.so.2.9.3 7f27098c7000-7f27098cf000 r-xp 0015d000 00:13 8004 /usr/lib/libxml2.so.2.9.3 7f27098cf000-7f27098d1000 rwxp 00165000 00:13 8004 /usr/lib/libxml2.so.2.9.3 7f27098d1000-7f27098d2000 rwxp 00000000 00:00 0 7f27098d2000-7f27098e7000 r-xp 00000000 00:13 7896 /usr/lib/libnsl-2.23.so 7f27098e7000-7f2709ae6000 ---p 00015000 00:13 7896 /usr/lib/libnsl-2.23.so 7f2709ae6000-7f2709ae7000 r-xp 00014000 00:13 7896 /usr/lib/libnsl-2.23.so 7f2709ae7000-7f2709ae8000 rwxp 00015000 00:13 7896 /usr/lib/libnsl-2.23.so 7f2709ae8000-7f2709aeb000 rwxp 00000000 00:00 0 7f2709aeb000-7f2709aed000 r-xp 00000000 00:13 7755 /usr/lib/libdl-2.23.so 7f2709aed000-7f2709ced000 ---p 00002000 00:13 7755 /usr/lib/libdl-2.23.so 7f2709ced000-7f2709cee000 r-xp 00002000 00:13 7755 /usr/lib/libdl-2.23.so 7f2709cee000-7f2709cef000 rwxp 00003000 00:13 7755 /usr/lib/libdl-2.23.so 7f2709cef000-7f2709df2000 r-xp 00000000 00:13 7872 /usr/lib/libm-2.23.so 7f2709df2000-7f2709ff2000 ---p 00103000 00:13 7872 /usr/lib/libm-2.23.so 7f2709ff2000-7f2709ff3000 r-xp 00103000 00:13 7872 /usr/lib/libm-2.23.so 7f2709ff3000-7f2709ff4000 rwxp 00104000 00:13 7872 /usr/lib/libm-2.23.so 7f2709ff4000-7f270a008000 r-xp 00000000 00:13 7934 /usr/lib/libresolv-2.23.so 7f270a008000-7f270a207000 ---p 00014000 00:13 7934 /usr/lib/libresolv-2.23.so 7f270a207000-7f270a208000 r-xp 00013000 00:13 7934 /usr/lib/libresolv-2.23.so 7f270a208000-7f270a209000 rwxp 00014000 00:13 7934 /usr/lib/libresolv-2.23.so 7f270a209000-7f270a20c000 rwxp 00000000 00:00 0 7f270a20c000-7f270a221000 r-xp 00000000 00:13 8008 /usr/lib/libz.so.1.2.8 7f270a221000-7f270a420000 ---p 00015000 00:13 8008 /usr/lib/libz.so.1.2.8 7f270a420000-7f270a421000 r-xp 00014000 00:13 8008 /usr/lib/libz.so.1.2.8 7f270a421000-7f270a422000 rwxp 00015000 00:13 8008 /usr/lib/libz.so.1.2.8 7f270a422000-7f270a42a000 r-xp 00000000 00:13 7747 /usr/lib/libcrypt-2.23.so 7f270a42a000-7f270a629000 ---p 00008000 00:13 7747 /usr/lib/libcrypt-2.23.so 7f270a629000-7f270a62a000 r-xp 00007000 00:13 7747 /usr/lib/libcrypt-2.23.so 7f270a62a000-7f270a62b000 rwxp 00008000 00:13 7747 /usr/lib/libcrypt-2.23.so 7f270a62b000-7f270a659000 rwxp 00000000 00:00 0 7f270a665000-7f270a666000 rwxp 00000000 00:00 0 7f270a666000-7f270a667000 r-xp 00000000 00:13 1726160 /usr/bin/daemon-preload.so 7f270a667000-7f270a866000 ---p 00001000 00:13 1726160 /usr/bin/daemon-preload.so 7f270a866000-7f270a867000 rwxp 00000000 00:13 1726160 /usr/bin/daemon-preload.so 7f270a867000-7f270a868000 rwxp 00000000 00:00 0 7f270a868000-7f270a88b000 r-xp 00000000 00:13 7564 /usr/lib/ld-2.23.so 7f270a88b000-7f270aa8b000 ---p 00000000 00:00 0 7f270aa8b000-7f270aa8c000 r-xp 00023000 00:13 7564 /usr/lib/ld-2.23.so 7f270aa8c000-7f270aa8d000 rwxp 00024000 00:13 7564 /usr/lib/ld-2.23.so 7f270aa8d000-7f270aa8e000 rwxp 00000000 00:00 0 7fffd4b65000-7fffd4b86000 rwxp 00000000 00:00 0 [stack] 7fffd4b9f000-7fffd4ba2000 r--p 00000000 00:00 0 [vvar] 7fffd4ba2000-7fffd4ba4000 r-xp 00000000 00:00 0 [vdso] ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall]
Process exited with code 134.