Skip to content

Commit

Permalink
Merge pull request chef#1560 from opscode/sersut/chef-1549
Browse files Browse the repository at this point in the history
Only check WOW64 process when system architecture is x64.
  • Loading branch information
Serdar Sutay committed Jun 26, 2014
2 parents e3478c4 + 40abdbc commit 64c7f8f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/chef/provider/windows_script.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ def initialize( new_resource, run_context, script_extension='')

@is_wow64 = wow64_architecture_override_required?(run_context.node, target_architecture)

if ( target_architecture == :i386 ) && ! is_i386_process_on_x86_64_windows?
# if the user wants to run the script 32 bit && we are on a 64bit windows system && we are running a 64bit ruby ==> fail
if ( target_architecture == :i386 ) && node_windows_architecture(run_context.node) == :x86_64 && !is_i386_process_on_x86_64_windows?
raise Chef::Exceptions::Win32ArchitectureIncorrect,
"Support for the i386 architecture from a 64-bit Ruby runtime is not yet implemented"
end
Expand Down

0 comments on commit 64c7f8f

Please sign in to comment.