Encode to binary before writing with OpenSSL::SSL::SSLSocket #189

Merged
merged 2 commits into from Feb 22, 2013

Conversation

Projects
None yet
2 participants
@eitoball
Contributor

eitoball commented Feb 21, 2013

This PR should fix MacRuby/MacRuby#188. The problem is Net::IMAP sends the content length in bytes to imap server, but OpenSSL::SSL:SSLSocket#print computes the content length in characters. That is why the patch sends the length in characters in the issue works.

The same fix in OpenSSL::Buffering is in MRI 1.9.3 or above.

@Watson1978

This comment has been minimized.

Show comment
Hide comment
@Watson1978

Watson1978 Feb 21, 2013

Maybe, we might need this changing too : ruby/ruby@65ca601#L1R337

Maybe, we might need this changing too : ruby/ruby@65ca601#L1R337

@eitoball

This comment has been minimized.

Show comment
Hide comment
@eitoball

eitoball Feb 22, 2013

Contributor

Maybe, we might need this changing too : ruby/ruby@65ca601#L1R337

I added the changes in ruby/ruby@65ca601 as @Watson1978 suggested. Actually, to fix #188, only #do_write needs to be fixed because Net::IMAP seems to use only #print and #print relies on #do_write.

Contributor

eitoball commented Feb 22, 2013

Maybe, we might need this changing too : ruby/ruby@65ca601#L1R337

I added the changes in ruby/ruby@65ca601 as @Watson1978 suggested. Actually, to fix #188, only #do_write needs to be fixed because Net::IMAP seems to use only #print and #print relies on #do_write.

Watson1978 added a commit that referenced this pull request Feb 22, 2013

Merge pull request #189 from eitoball/encode_to_binary_before_writing…
…_with_ssl_socket

Encode to binary before writing with OpenSSL::SSL::SSLSocket

@Watson1978 Watson1978 merged commit 5c352cf into MacRuby:master Feb 22, 2013

@Watson1978

This comment has been minimized.

Show comment
Hide comment
@Watson1978

Watson1978 Feb 22, 2013

Member

Thanks !!

Member

Watson1978 commented Feb 22, 2013

Thanks !!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment