Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Curl::Multi.download error handling issue #269

Open
sriedel opened this issue Nov 12, 2015 · 0 comments
Open

Curl::Multi.download error handling issue #269

sriedel opened this issue Nov 12, 2015 · 0 comments

Comments

@sriedel
Copy link
Contributor

sriedel commented Nov 12, 2015

If an error was encountered, Curl::Multi.download does an

      ensure                                                                    
         # ...                                                                  
        raise errors unless errors.empty?                                       
      end  

However errors is an array and ruby cannot raise an array of errors:

2.2.3 :001 > raise StandardError.new
StandardError: StandardError
        from (irb):1
        from /home/sr/.rvm/rubies/ruby-2.2.3/bin/irb:11:in `<main>'
2.2.3 :002 > raise [ StandardError.new, StandardError.new ]
TypeError: exception class/object expected
        from (irb):2:in `raise'
        from (irb):2
        from /home/sr/.rvm/rubies/ruby-2.2.3/bin/irb:11:in `<main>'

taf2 added a commit that referenced this issue Dec 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant