Land #10857, ensure os_flavor can be supplied for non Windows OS

4.x
Brent Cook 2018-10-24 14:28:32 -05:00 committed by Jeffrey Martin
parent 993ceb0d1a
commit 4d2002f98a
No known key found for this signature in database
GPG Key ID: 0CD9BBC2AF15F171
1 changed files with 3 additions and 1 deletions

View File

@ -196,7 +196,9 @@ module Msf::DBManager::Host
os_name, os_flavor = split_windows_os_name(opts[:os_name])
opts[:os_name] = os_name if os_name.present?
if opts[:os_flavor].present?
opts[:os_flavor] = os_flavor + opts[:os_flavor]
if os_flavor.present? # only prepend if there is a value that needs it
opts[:os_flavor] = os_flavor + opts[:os_flavor]
end
else
opts[:os_flavor] = os_flavor
end