From 796884e0e279777167e83cb22e0c7893f14f39cb Mon Sep 17 00:00:00 2001 From: Pascal Terjan Date: Wed, 2 Jun 2010 09:56:19 +0000 Subject: preserve sockets and pipes in cp_af --- lib/MDK/Common/File.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/MDK/Common') diff --git a/lib/MDK/Common/File.pm b/lib/MDK/Common/File.pm index cacad59..06bd4fe 100644 --- a/lib/MDK/Common/File.pm +++ b/lib/MDK/Common/File.pm @@ -214,7 +214,7 @@ sub cp_with_option { } elsif (-d $src) { -d $dest or mkdir $dest, (stat($src))[2] or die "mkdir: can't create directory $dest: $!\n"; cp_with_option($option, glob_($src), $dest); - } elsif ((-b $src || -c $src) && $keep_special) { + } elsif ((-b $src || -c $src || -S $src || -p $src) && $keep_special) { my @stat = stat($src); require MDK::Common::System; MDK::Common::System::syscall_('mknod', $dest, $stat[2], $stat[6]) or die "mknod failed (dev $dest): $!"; -- cgit v1.2.1