[#86787] [Ruby trunk Feature#14723] [WIP] sleepy GC — ko1@...

Issue #14723 has been updated by ko1 (Koichi Sasada).

13 messages 2018/05/01
[#86790] Re: [Ruby trunk Feature#14723] [WIP] sleepy GC — Eric Wong <normalperson@...> 2018/05/01

ko1@atdot.net wrote:

[#87095] [Ruby trunk Feature#14767] [PATCH] gc.c: use monotonic counters for objspace_malloc_increase — ko1@...

Issue #14767 has been updated by ko1 (Koichi Sasada).

9 messages 2018/05/17
[#87096] Re: [Ruby trunk Feature#14767] [PATCH] gc.c: use monotonic counters for objspace_malloc_increase — Eric Wong <normalperson@...> 2018/05/17

ko1@atdot.net wrote:

[ruby-core:87000] [Ruby trunk Bug#14750] [IMAP] `send_string_data` uses `send_literal` method with incorrect number of arguments

From: shugo@...
Date: 2018-05-11 22:08:22 UTC
List: ruby-core #87000
Issue #14750 has been updated by shugo (Shugo Maeda).

Backport changed from 2.3: UNKNOWN, 2.4: UNKNOWN, 2.5: UNKNOWN to 2.3: DONTNEED, 2.4: DONTNEED, 2.5: REQUIRED

ShockwaveNN (Pavel Lobashov) wrote:
> Thanks for quick fix, I monkeypatched my code using your fix and working as intended.
> Does this fix will be included in next bugfix of 2.5? Or it will be included only in 2.6?

I think the fix should be backported to 2.5.


----------------------------------------
Bug #14750: [IMAP] `send_string_data` uses `send_literal` method with incorrect number of arguments
https://bugs.ruby-lang.org/issues/14750#change-71969

* Author: ShockwaveNN (Pavel Lobashov)
* Status: Closed
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-linux]
* Backport: 2.3: DONTNEED, 2.4: DONTNEED, 2.5: REQUIRED
----------------------------------------
Hi there, sorry I haven't reliable test case to reproduce an issue, since I don't have access to any public IMAP servers.

In Ruby 2.5 in file `lib/net/imap.rb` there is method `def send_string_data` which looks like 

~~~ ruby
def send_string_data(str)
  ...
  send_literal(str)
  ...
end
~~~

See https://github.com/ruby/ruby/blob/ruby_2_5/lib/net/imap.rb#L1346

But method `send_literal` defined as 

~~~ ruby
def send_literal(str, tag)
~~~


See https://github.com/ruby/ruby/blob/ruby_2_5/lib/net/imap.rb#L1359

Second argumen, `tag` is not optional, so `send_string_data` fail with `wrong number of arguments (given 1, expected 2)` error

This was introduced https://github.com/ruby/ruby/commit/84c1596342854208c45832ed9700482dd28efbfc
Some places was changed for new two argument syntax, but `send_literal` in `send_string_data` was forgontten



-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>

In This Thread

Prev Next