Skip to content

Commit

Permalink
StreamableStream now uses the OS temp directory.
Browse files Browse the repository at this point in the history
Rather than using the local folder.

Fixes rubyzip#410
  • Loading branch information
hainesr committed Sep 27, 2019
1 parent 2825898 commit 506d557
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions lib/zip/streamable_stream.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@ module Zip
class StreamableStream < DelegateClass(Entry) # nodoc:all
def initialize(entry)
super(entry)
dirname = if zipfile.is_a?(::String)
::File.dirname(zipfile)
else
nil
end
@temp_file = Tempfile.new(::File.basename(name), dirname)
@temp_file = Tempfile.new(::File.basename(name))
@temp_file.binmode
end

Expand Down

0 comments on commit 506d557

Please sign in to comment.