Sha256: 029e65f89d5a82cfff2cd0cba57fab75143ba79e9f6b4b4ed62c09c405c57366

Contents?: true

Size: 619 Bytes

Versions: 17

Compression:

Stored size: 619 Bytes

Contents

# frozen_string_literal: true

module Puma
  module MiniSSL
    class Socket
      def read_nonblock(size, *_)
        loop do
          output = engine_read_all
          return output if output

          data = @socket.read_nonblock(size, exception: false)
          raise IO::EAGAINWaitReadable if %i[wait_readable wait_writable].include? data
          return nil if data.nil?

          @engine.inject(data)
          output = engine_read_all

          return output if output

          while (neg_data = @engine.extract)
            @socket.write neg_data
          end
        end
      end
    end
  end
end

Version data entries

17 entries across 14 versions & 3 rubygems

Version Path
tdiary-5.1.3 vendor/bundle/ruby/2.7.0/gems/capybara-3.33.0/lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.3 vendor/bundle/ruby/2.6.0/gems/capybara-3.32.2/lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.33.0 lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.2 vendor/bundle/ruby/2.7.0/gems/capybara-3.32.2/lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.2 vendor/bundle/ruby/2.6.0/gems/capybara-3.29.0/lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.32.2 lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.32.1 lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.32.0 lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.1 vendor/bundle/ruby/2.6.0/gems/capybara-3.29.0/lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.1 vendor/bundle/ruby/2.7.0/gems/capybara-3.31.0/lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.31.0 lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.30.0 lib/capybara/registrations/patches/puma_ssl.rb
tdiary-5.1.0 vendor/bundle/gems/capybara-3.29.0/lib/capybara/registrations/patches/puma_ssl.rb
chatops-rpc-0.0.2 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/capybara-3.29.0/lib/capybara/registrations/patches/puma_ssl.rb
chatops-rpc-0.0.1 fixtures/chatops-controller-example/vendor/bundle/ruby/2.5.0/gems/capybara-3.29.0/lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.29.0 lib/capybara/registrations/patches/puma_ssl.rb
capybara-3.28.0 lib/capybara/registrations/patches/puma_ssl.rb