Skip to content

Commit

Permalink
Vlc path parsing fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JBlackN committed Sep 16, 2015
1 parent 1f61046 commit a29f7a3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/budik/player.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ def vlc(source)
end

def vlc_build_command(source)
vlc_path = @player_options['path']
vlc_path.gsub!(/^/, '"').gsub!(/$/, '"') if vlc_path =~ /\s/
vlc_path = Marshal.load(Marshal.dump(@player_options['path']))
vlc_path.gsub!(/(^|$)/, '"') if vlc_path =~ /\s/

args = vlc_build_args
files = vlc_cmd_add_items(source)
Expand Down
1 change: 0 additions & 1 deletion spec/lib/budik/player_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@

source = { path: %w(path1 path2) }
cmd = player.vlc_build_command(source)
player.player_options['path'].gsub!(/^"/, '').gsub!(/"$/, '')

expect(player).to receive(:spawn).with(cmd)
allow(player).to receive(:vlc_volume_control) {}
Expand Down

0 comments on commit a29f7a3

Please sign in to comment.