summaryrefslogtreecommitdiff
path: root/ext/standard/tests/file/copy_variation4.phpt
blob: e656210fa9085b05aae7c066aac3fe5f8afb5528 (plain)
ofshex dumpascii
0000 2d 2d 54 45 53 54 2d 2d 0a 54 65 73 74 20 63 6f 70 79 28 29 20 66 75 6e 63 74 69 6f 6e 3a 20 75 --TEST--.Test.copy().function:.u
0020 73 61 67 65 20 76 61 72 69 61 74 69 6f 6e 73 20 2d 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 sage.variations.-.destination.fi
0040 6c 65 20 6e 61 6d 65 73 28 65 6d 70 74 79 20 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 73 20 26 20 62 le.names(empty.string,.nulls.&.b
0060 6f 6f 6c 73 29 0a 2d 2d 53 4b 49 50 49 46 2d 2d 0a 3c 3f 70 68 70 0a 69 66 28 73 75 62 73 74 72 ools).--SKIPIF--.<?php.if(substr
0080 28 50 48 50 5f 4f 53 2c 20 30 2c 20 33 29 20 3d 3d 20 22 57 49 4e 22 29 0a 20 20 64 69 65 28 22 (PHP_OS,.0,.3).==."WIN")...die("
00a0 73 6b 69 70 20 44 6f 20 6e 6f 74 20 72 75 6e 20 6f 6e 20 57 69 6e 64 6f 77 73 22 29 3b 0a 3f 3e skip.Do.not.run.on.Windows");.?>
00c0 0a 2d 2d 46 49 4c 45 2d 2d 0a 3c 3f 70 68 70 0a 2f 2a 20 50 72 6f 74 6f 74 79 70 65 3a 20 62 6f .--FILE--.<?php./*.Prototype:.bo
00e0 6f 6c 20 63 6f 70 79 20 28 20 73 74 72 69 6e 67 20 24 73 6f 75 72 63 65 2c 20 73 74 72 69 6e 67 ol.copy.(.string.$source,.string
0100 20 24 64 65 73 74 20 29 3b 0a 20 20 20 44 65 73 63 72 69 70 74 69 6f 6e 3a 20 4d 61 6b 65 73 20 .$dest.);....Description:.Makes.
0120 61 20 63 6f 70 79 20 6f 66 20 74 68 65 20 66 69 6c 65 20 73 6f 75 72 63 65 20 74 6f 20 64 65 73 a.copy.of.the.file.source.to.des
0140 74 2e 0a 20 20 20 20 20 52 65 74 75 72 6e 73 20 54 52 55 45 20 6f 6e 20 73 75 63 63 65 73 73 20 t.......Returns.TRUE.on.success.
0160 6f 72 20 46 41 4c 53 45 20 6f 6e 20 66 61 69 6c 75 72 65 2e 0a 2a 2f 0a 0a 2f 2a 20 54 65 73 74 or.FALSE.on.failure..*/../*.Test
0180 20 63 6f 70 79 28 29 20 66 75 6e 63 74 69 6f 6e 3a 20 49 6e 20 63 72 65 61 74 69 6f 6e 20 6f 66 .copy().function:.In.creation.of
01a0 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 73 20 77 69 74 68 20 65 6d 70 .destination.file.names.with.emp
01c0 74 79 20 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 73 20 26 20 62 6f 6f 6c 73 20 0a 20 20 20 20 20 61 ty.string,.nulls.&.bools.......a
01e0 6e 64 20 63 68 65 63 6b 69 6e 67 20 74 68 65 20 65 78 69 73 74 65 6e 63 65 20 61 6e 64 20 73 69 nd.checking.the.existence.and.si
0200 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 73 0a 2a 2f 0a 0a 65 63 68 6f ze.of.destination.files.*/..echo
0220 20 22 2a 2a 2a 20 54 65 73 74 20 63 6f 70 79 28 29 20 66 75 6e 63 74 69 6f 6e 3a 20 64 65 73 74 ."***.Test.copy().function:.dest
0240 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 73 20 77 69 74 68 20 65 6d 70 74 79 20 73 74 ination.file.names.with.empty.st
0260 72 69 6e 67 2c 20 6e 75 6c 6c 73 20 26 20 62 6f 6f 6c 73 20 2a 2a 2a 5c 6e 22 3b 0a 24 66 69 6c ring,.nulls.&.bools.***\n";.$fil
0280 65 5f 70 61 74 68 20 3d 20 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 5f 5f 29 3b 0a 24 73 72 63 e_path.=.dirname(__FILE__);.$src
02a0 5f 66 69 6c 65 5f 6e 61 6d 65 20 3d 20 24 66 69 6c 65 5f 70 61 74 68 2e 22 2f 63 6f 70 79 5f 76 _file_name.=.$file_path."/copy_v
02c0 61 72 69 61 74 69 6f 6e 34 2e 74 6d 70 22 3b 0a 24 66 69 6c 65 5f 68 61 6e 64 6c 65 20 3d 20 66 ariation4.tmp";.$file_handle.=.f
02e0 6f 70 65 6e 28 24 73 72 63 5f 66 69 6c 65 5f 6e 61 6d 65 2c 20 22 77 22 29 3b 0a 66 77 72 69 74 open($src_file_name,."w");.fwrit
0300 65 28 20 24 66 69 6c 65 5f 68 61 6e 64 6c 65 2c 20 73 74 72 5f 72 65 70 65 61 74 28 62 22 48 65 e(.$file_handle,.str_repeat(b"He
0320 6c 6c 6f 32 57 6f 72 6c 64 2e 2e 2e 5c 6e 22 2c 20 31 30 30 29 20 29 3b 0a 66 63 6c 6f 73 65 28 llo2World...\n",.100).);.fclose(
0340 24 66 69 6c 65 5f 68 61 6e 64 6c 65 29 3b 0a 0a 2f 2a 20 61 72 72 61 79 20 6f 66 20 64 65 73 74 $file_handle);../*.array.of.dest
0360 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 73 20 2a 2f 0a 24 64 65 73 74 5f 66 69 6c 65 ination.file.names.*/.$dest_file
0380 73 20 3d 20 61 72 72 61 79 28 0a 0a 20 20 2f 2a 20 46 69 6c 65 20 6e 61 6d 65 73 20 63 6f 6e 74 s.=.array(..../*.File.names.cont
03a0 61 69 6e 69 6e 67 28 6f 72 20 77 69 74 68 29 20 6e 75 6c 6c 73 20 2a 2f 0a 20 20 22 22 2c 20 0a aining(or.with).nulls.*/..."",..
03c0 20 20 4e 55 4c 4c 2c 0a 20 20 22 5c 30 22 2c 0a 20 20 46 41 4c 53 45 2c 0a 20 20 66 61 6c 73 65 ..NULL,..."\0",...FALSE,...false
03e0 2c 0a 20 20 54 52 55 45 2c 0a 20 20 74 72 75 65 0a 29 3b 0a 0a 65 63 68 6f 20 22 53 69 7a 65 20 ,...TRUE,...true.);..echo."Size.
0400 6f 66 20 74 68 65 20 73 6f 75 72 63 65 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 79 20 6f of.the.source.file.before.copy.o
0420 70 65 72 61 74 69 6f 6e 20 3d 3e 20 22 3b 0a 76 61 72 5f 64 75 6d 70 28 20 66 69 6c 65 73 69 7a peration.=>.";.var_dump(.filesiz
0440 65 28 24 73 72 63 5f 66 69 6c 65 5f 6e 61 6d 65 29 20 29 3b 0a 63 6c 65 61 72 73 74 61 74 63 61 e($src_file_name).);.clearstatca
0460 63 68 65 28 29 3b 0a 0a 65 63 68 6f 20 22 5c 6e 2d 2d 20 4e 6f 77 20 61 70 70 6c 79 69 6e 67 20 che();..echo."\n--.Now.applying.
0480 63 6f 70 79 28 29 20 6f 6e 20 73 6f 75 72 63 65 20 66 69 6c 65 20 74 6f 20 63 72 65 61 74 65 20 copy().on.source.file.to.create.
04a0 63 6f 70 69 65 73 20 2d 2d 22 3b 0a 24 63 6f 75 6e 74 20 3d 20 31 3b 0a 66 6f 72 65 61 63 68 28 copies.--";.$count.=.1;.foreach(
04c0 24 64 65 73 74 5f 66 69 6c 65 73 20 61 73 20 24 64 65 73 74 5f 66 69 6c 65 29 20 7b 0a 20 20 65 $dest_files.as.$dest_file).{...e
04e0 63 68 6f 20 22 5c 6e 2d 2d 20 49 74 65 72 61 74 69 6f 6e 20 24 63 6f 75 6e 74 20 2d 2d 5c 6e 22 cho."\n--.Iteration.$count.--\n"
0500 3b 0a 20 20 24 64 65 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 20 3d 20 24 66 69 6c 65 5f 70 61 74 68 ;...$dest_file_name.=.$file_path
0520 2e 22 2f 24 64 65 73 74 5f 66 69 6c 65 22 3b 0a 0a 20 20 65 63 68 6f 20 22 45 78 69 73 74 65 6e ."/$dest_file";....echo."Existen
0540 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f ce.of.destination.file.before.co
0560 70 79 20 3d 3e 20 22 3b 0a 20 20 76 61 72 5f 64 75 6d 70 28 20 66 69 6c 65 5f 65 78 69 73 74 73 py.=>.";...var_dump(.file_exists
0580 28 24 64 65 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 29 20 29 3b 0a 0a 20 20 65 63 68 6f 20 22 43 6f ($dest_file_name).);....echo."Co
05a0 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 22 3b 0a 20 20 76 61 72 5f 64 75 6d 70 28 20 63 py.operation.=>.";...var_dump(.c
05c0 6f 70 79 28 24 73 72 63 5f 66 69 6c 65 5f 6e 61 6d 65 2c 20 24 64 65 73 74 5f 66 69 6c 65 5f 6e opy($src_file_name,.$dest_file_n
05e0 61 6d 65 29 20 29 3b 0a 0a 20 20 65 63 68 6f 20 22 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 ame).);....echo."Existence.of.de
0600 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 22 3b 0a 20 20 76 61 72 5f 64 75 6d 70 28 stination.file.=>.";...var_dump(
0620 20 66 69 6c 65 5f 65 78 69 73 74 73 28 24 64 65 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 29 20 29 3b .file_exists($dest_file_name).);
0640 0a 0a 20 20 65 63 68 6f 20 22 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 20 ....echo."Destination.file.name.
0660 3d 3e 20 22 3b 0a 20 20 70 72 69 6e 74 28 24 64 65 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 29 3b 0a =>.";...print($dest_file_name);.
0680 20 20 65 63 68 6f 20 22 5c 6e 22 3b 0a 0a 20 20 65 63 68 6f 20 22 53 69 7a 65 20 6f 66 20 73 6f ..echo."\n";....echo."Size.of.so
06a0 75 72 63 65 20 66 69 6c 65 20 3d 3e 20 22 3b 0a 20 20 76 61 72 5f 64 75 6d 70 28 20 66 69 6c 65 urce.file.=>.";...var_dump(.file
06c0 73 69 7a 65 28 24 73 72 63 5f 66 69 6c 65 5f 6e 61 6d 65 29 20 29 3b 0a 20 20 63 6c 65 61 72 73 size($src_file_name).);...clears
06e0 74 61 74 63 61 63 68 65 28 29 3b 0a 0a 20 20 65 63 68 6f 20 22 53 69 7a 65 20 6f 66 20 64 65 73 tatcache();....echo."Size.of.des
0700 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 22 3b 0a 20 20 76 61 72 5f 64 75 6d 70 28 20 tination.file.=>.";...var_dump(.
0720 66 69 6c 65 73 69 7a 65 28 24 64 65 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 29 20 29 3b 0a 20 20 63 filesize($dest_file_name).);...c
0740 6c 65 61 72 73 74 61 74 63 61 63 68 65 28 29 3b 0a 20 20 0a 20 20 75 6e 6c 69 6e 6b 28 24 64 65 learstatcache();......unlink($de
0760 73 74 5f 66 69 6c 65 5f 6e 61 6d 65 29 3b 0a 0a 20 20 24 63 6f 75 6e 74 2b 2b 3b 0a 0a 7d 0a 0a st_file_name);....$count++;..}..
0780 65 63 68 6f 20 22 2a 2a 2a 20 44 6f 6e 65 20 2a 2a 2a 5c 6e 22 3b 0a 3f 3e 0a 0a 2d 2d 43 4c 45 echo."***.Done.***\n";.?>..--CLE
07a0 41 4e 2d 2d 0a 3c 3f 70 68 70 0a 75 6e 6c 69 6e 6b 28 64 69 72 6e 61 6d 65 28 5f 5f 46 49 4c 45 AN--.<?php.unlink(dirname(__FILE
07c0 5f 5f 29 2e 22 2f 63 6f 70 79 5f 76 61 72 69 61 74 69 6f 6e 34 2e 74 6d 70 22 29 3b 0a 3f 3e 0a __)."/copy_variation4.tmp");.?>.
07e0 0a 2d 2d 45 58 50 45 43 54 46 2d 2d 0a 2a 2a 2a 20 54 65 73 74 20 63 6f 70 79 28 29 20 66 75 6e .--EXPECTF--.***.Test.copy().fun
0800 63 74 69 6f 6e 3a 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 73 20 77 69 ction:.destination.file.names.wi
0820 74 68 20 65 6d 70 74 79 20 73 74 72 69 6e 67 2c 20 6e 75 6c 6c 73 20 26 20 62 6f 6f 6c 73 20 2a th.empty.string,.nulls.&.bools.*
0840 2a 2a 0a 53 69 7a 65 20 6f 66 20 74 68 65 20 73 6f 75 72 63 65 20 66 69 6c 65 20 62 65 66 6f 72 **.Size.of.the.source.file.befor
0860 65 20 63 6f 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 0a 2d e.copy.operation.=>.int(1500)..-
0880 2d 20 4e 6f 77 20 61 70 70 6c 79 69 6e 67 20 63 6f 70 79 28 29 20 6f 6e 20 73 6f 75 72 63 65 20 -.Now.applying.copy().on.source.
08a0 66 69 6c 65 20 74 6f 20 63 72 65 61 74 65 20 63 6f 70 69 65 73 20 2d 2d 0a 2d 2d 20 49 74 65 72 file.to.create.copies.--.--.Iter
08c0 61 74 69 6f 6e 20 31 20 2d 2d 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 ation.1.--.Existence.of.destinat
08e0 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 79 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 ion.file.before.copy.=>.bool(tru
0900 65 29 0a 43 6f 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 0a 57 61 72 6e 69 6e 67 3a 20 63 e).Copy.operation.=>..Warning:.c
0920 6f 70 79 28 25 73 29 3a 20 66 61 69 6c 65 64 20 74 6f 20 6f 70 65 6e 20 73 74 72 65 61 6d 3a 20 opy(%s):.failed.to.open.stream:.
0940 49 73 20 61 20 64 69 72 65 63 74 6f 72 79 20 69 6e 20 25 73 20 6f 6e 20 6c 69 6e 65 20 25 64 0a Is.a.directory.in.%s.on.line.%d.
0960 62 6f 6f 6c 28 66 61 6c 73 65 29 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 bool(false).Existence.of.destina
0980 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 tion.file.=>.bool(true).Destinat
09a0 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 20 3d 3e 20 25 73 2f 0a 53 69 7a 65 20 6f 66 20 73 6f 75 ion.file.name.=>.%s/.Size.of.sou
09c0 72 63 65 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 rce.file.=>.int(1500).Size.of.de
09e0 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 25 64 29 0a 0a 57 61 72 6e 69 stination.file.=>.int(%d)..Warni
0a00 6e 67 3a 20 75 6e 6c 69 6e 6b 28 25 73 29 3a 20 25 73 0a 0a 2d 2d 20 49 74 65 72 61 74 69 6f 6e ng:.unlink(%s):.%s..--.Iteration
0a20 20 32 20 2d 2d 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 .2.--.Existence.of.destination.f
0a40 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 79 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 43 6f ile.before.copy.=>.bool(true).Co
0a60 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 0a 57 61 72 6e 69 6e 67 3a 20 63 6f 70 79 28 25 py.operation.=>..Warning:.copy(%
0a80 73 29 3a 20 66 61 69 6c 65 64 20 74 6f 20 6f 70 65 6e 20 73 74 72 65 61 6d 3a 20 49 73 20 61 20 s):.failed.to.open.stream:.Is.a.
0aa0 64 69 72 65 63 74 6f 72 79 20 69 6e 20 25 73 20 6f 6e 20 6c 69 6e 65 20 25 64 0a 62 6f 6f 6c 28 directory.in.%s.on.line.%d.bool(
0ac0 66 61 6c 73 65 29 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 false).Existence.of.destination.
0ae0 66 69 6c 65 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 file.=>.bool(true).Destination.f
0b00 69 6c 65 20 6e 61 6d 65 20 3d 3e 20 25 73 2f 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 65 20 66 ile.name.=>.%s/.Size.of.source.f
0b20 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 ile.=>.int(1500).Size.of.destina
0b40 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 25 64 29 0a 0a 57 61 72 6e 69 6e 67 3a 20 75 tion.file.=>.int(%d)..Warning:.u
0b60 6e 6c 69 6e 6b 28 25 73 29 3a 20 25 73 0a 0a 2d 2d 20 49 74 65 72 61 74 69 6f 6e 20 33 20 2d 2d nlink(%s):.%s..--.Iteration.3.--
0b80 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 62 .Existence.of.destination.file.b
0ba0 65 66 6f 72 65 20 63 6f 70 79 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 43 6f 70 79 20 6f 70 efore.copy.=>.bool(true).Copy.op
0bc0 65 72 61 74 69 6f 6e 20 3d 3e 20 0a 57 61 72 6e 69 6e 67 3a 20 63 6f 70 79 28 25 73 29 3a 20 66 eration.=>..Warning:.copy(%s):.f
0be0 61 69 6c 65 64 20 74 6f 20 6f 70 65 6e 20 73 74 72 65 61 6d 3a 20 49 73 20 61 20 64 69 72 65 63 ailed.to.open.stream:.Is.a.direc
0c00 74 6f 72 79 20 69 6e 20 25 73 20 6f 6e 20 6c 69 6e 65 20 25 64 0a 62 6f 6f 6c 28 66 61 6c 73 65 tory.in.%s.on.line.%d.bool(false
0c20 29 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 ).Existence.of.destination.file.
0c40 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e =>.bool(true).Destination.file.n
0c60 61 6d 65 20 3d 3e 20 25 73 2f 00 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 65 20 66 69 6c 65 20 ame.=>.%s/..Size.of.source.file.
0c80 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e =>.int(1500).Size.of.destination
0ca0 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 25 64 29 0a 0a 57 61 72 6e 69 6e 67 3a 20 75 6e 6c 69 6e .file.=>.int(%d)..Warning:.unlin
0cc0 6b 28 25 73 29 3a 20 25 73 0a 0a 2d 2d 20 49 74 65 72 61 74 69 6f 6e 20 34 20 2d 2d 0a 45 78 69 k(%s):.%s..--.Iteration.4.--.Exi
0ce0 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 stence.of.destination.file.befor
0d00 65 20 63 6f 70 79 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 43 6f 70 79 20 6f 70 65 72 61 74 e.copy.=>.bool(true).Copy.operat
0d20 69 6f 6e 20 3d 3e 20 0a 57 61 72 6e 69 6e 67 3a 20 63 6f 70 79 28 25 73 29 3a 20 66 61 69 6c 65 ion.=>..Warning:.copy(%s):.faile
0d40 64 20 74 6f 20 6f 70 65 6e 20 73 74 72 65 61 6d 3a 20 49 73 20 61 20 64 69 72 65 63 74 6f 72 79 d.to.open.stream:.Is.a.directory
0d60 20 69 6e 20 25 73 20 6f 6e 20 6c 69 6e 65 20 25 64 0a 62 6f 6f 6c 28 66 61 6c 73 65 29 0a 45 78 .in.%s.on.line.%d.bool(false).Ex
0d80 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 62 istence.of.destination.file.=>.b
0da0 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 20 ool(true).Destination.file.name.
0dc0 3d 3e 20 25 73 2f 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 65 20 66 69 6c 65 20 3d 3e 20 69 6e =>.%s/.Size.of.source.file.=>.in
0de0 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 t(1500).Size.of.destination.file
0e00 20 3d 3e 20 69 6e 74 28 25 64 29 0a 0a 57 61 72 6e 69 6e 67 3a 20 75 6e 6c 69 6e 6b 28 25 73 29 .=>.int(%d)..Warning:.unlink(%s)
0e20 3a 20 25 73 0a 0a 2d 2d 20 49 74 65 72 61 74 69 6f 6e 20 35 20 2d 2d 0a 45 78 69 73 74 65 6e 63 :.%s..--.Iteration.5.--.Existenc
0e40 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 e.of.destination.file.before.cop
0e60 79 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 43 6f 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d y.=>.bool(true).Copy.operation.=
0e80 3e 20 0a 57 61 72 6e 69 6e 67 3a 20 63 6f 70 79 28 25 73 29 3a 20 66 61 69 6c 65 64 20 74 6f 20 >..Warning:.copy(%s):.failed.to.
0ea0 6f 70 65 6e 20 73 74 72 65 61 6d 3a 20 49 73 20 61 20 64 69 72 65 63 74 6f 72 79 20 69 6e 20 25 open.stream:.Is.a.directory.in.%
0ec0 73 20 6f 6e 20 6c 69 6e 65 20 25 64 0a 62 6f 6f 6c 28 66 61 6c 73 65 29 0a 45 78 69 73 74 65 6e s.on.line.%d.bool(false).Existen
0ee0 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 62 6f 6f 6c 28 74 ce.of.destination.file.=>.bool(t
0f00 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 6e 61 6d 65 20 3d 3e 20 25 73 rue).Destination.file.name.=>.%s
0f20 2f 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 65 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 /.Size.of.source.file.=>.int(150
0f40 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 69 0).Size.of.destination.file.=>.i
0f60 6e 74 28 25 64 29 0a 0a 57 61 72 6e 69 6e 67 3a 20 75 6e 6c 69 6e 6b 28 25 73 29 3a 20 25 73 0a nt(%d)..Warning:.unlink(%s):.%s.
0f80 0a 2d 2d 20 49 74 65 72 61 74 69 6f 6e 20 36 20 2d 2d 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 .--.Iteration.6.--.Existence.of.
0fa0 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 79 20 3d 3e 20 destination.file.before.copy.=>.
0fc0 62 6f 6f 6c 28 66 61 6c 73 65 29 0a 43 6f 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 62 6f bool(false).Copy.operation.=>.bo
0fe0 6f 6c 28 74 72 75 65 29 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f ol(true).Existence.of.destinatio
1000 6e 20 66 69 6c 65 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e n.file.=>.bool(true).Destination
1020 20 66 69 6c 65 20 6e 61 6d 65 20 3d 3e 20 25 73 2f 31 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 .file.name.=>.%s/1.Size.of.sourc
1040 65 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 e.file.=>.int(1500).Size.of.dest
1060 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 0a 2d 2d 20 49 74 ination.file.=>.int(1500)..--.It
1080 65 72 61 74 69 6f 6e 20 37 20 2d 2d 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e eration.7.--.Existence.of.destin
10a0 61 74 69 6f 6e 20 66 69 6c 65 20 62 65 66 6f 72 65 20 63 6f 70 79 20 3d 3e 20 62 6f 6f 6c 28 66 ation.file.before.copy.=>.bool(f
10c0 61 6c 73 65 29 0a 43 6f 70 79 20 6f 70 65 72 61 74 69 6f 6e 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 alse).Copy.operation.=>.bool(tru
10e0 65 29 0a 45 78 69 73 74 65 6e 63 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 e).Existence.of.destination.file
1100 20 3d 3e 20 62 6f 6f 6c 28 74 72 75 65 29 0a 44 65 73 74 69 6e 61 74 69 6f 6e 20 66 69 6c 65 20 .=>.bool(true).Destination.file.
1120 6e 61 6d 65 20 3d 3e 20 25 73 2f 31 0a 53 69 7a 65 20 6f 66 20 73 6f 75 72 63 65 20 66 69 6c 65 name.=>.%s/1.Size.of.source.file
1140 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 53 69 7a 65 20 6f 66 20 64 65 73 74 69 6e 61 74 69 6f .=>.int(1500).Size.of.destinatio
1160 6e 20 66 69 6c 65 20 3d 3e 20 69 6e 74 28 31 35 30 30 29 0a 2a 2a 2a 20 44 6f 6e 65 20 2a 2a 2a n.file.=>.int(1500).***.Done.***
1180 0a .