Author: arkurth
Date: Thu Jul  9 17:44:28 2009
New Revision: 792617

URL: http://svn.apache.org/viewvc?rev=792617&view=rev
Log:
VCL-23
Fixed bug in filesystem_entry_exists() sub. Removed /s switch from dir command. 
It was returning true if a file didn't exist, but a file with a similar name 
exists under a subdirectory.

Modified:
    incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm

Modified: incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm
URL: 
http://svn.apache.org/viewvc/incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm?rev=792617&r1=792616&r2=792617&view=diff
==============================================================================
--- incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm 
(original)
+++ incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows_mod.pm Thu Jul 
 9 17:44:28 2009
@@ -1099,7 +1099,7 @@
        $path =~ s/[\\\/]+/\\/g;
 
        # Assemble the dir command and execute it
-       my $dir_command = "cmd.exe /c dir /a /b /s \"$path\"";
+       my $dir_command = "cmd.exe /c dir /a /b \"$path\"";
        my ($dir_exit_status, $dir_output) = 
run_ssh_command($computer_node_name, $management_node_keys, $dir_command, '', 
'', 1);
        if ((defined($dir_exit_status) && $dir_exit_status == 0) || 
(defined($dir_output) && grep(/$path/i, @$dir_output))) {
                notify($ERRORS{'DEBUG'}, 0, "filesystem entry exists on 
$computer_node_name: $path, dir output:\n" . join("\n", @$dir_output));


Reply via email to