Forum: Ruby-core [ruby-trunk - Bug #8774][Open] rb_file_dirname return wrong encoding string when dir is "."

Eaddc575a02d805ab3e8777c5ea921d0?d=identicon&s=25 "jiayp@glodon.com (贾 延平)" <jiayp@glodon.com> (Guest)
on 2013-08-11 08:29
(Received via mailing list)
Issue #8774 has been reported by jiayp@glodon.com (贾 延平).

----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774

Author: jiayp@glodon.com (贾 延平)
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
F1d6cc2b735bfd82c8773172da2aeab9?d=identicon&s=25 Nobuyoshi Nakada (nobu)
on 2013-08-11 11:16
(Received via mailing list)
Issue #8774 has been updated by nobu (Nobuyoshi Nakada).

Status changed from Open to Feedback

"." is 7bit only, it has no differences.

Why do you consider it wrong?
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41086

Author: jiayp@glodon.com (贾 延平)
Status: Feedback
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
Eaddc575a02d805ab3e8777c5ea921d0?d=identicon&s=25 "jiayp@glodon.com (贾 延平)" <jiayp@glodon.com> (Guest)
on 2013-08-12 05:12
(Received via mailing list)
Issue #8774 has been updated by jiayp@glodon.com (贾 延平).


The rb_file_dirname should not return diffrent encoding string value
just because the string's content diffrent.
And some other function like rb_file_expand_path will return the value
with the input paramter's incoding,and the result is not 7bit string.
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41098

Author: jiayp@glodon.com (贾 延平)
Status: Feedback
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
E5fa308f01c66b3e67773422edf1473a?d=identicon&s=25 "jiayp@glodon.com (贾 延平)" <yanping_jia@hotmail.com (Guest)
on 2013-08-14 02:37
(Received via mailing list)
Issue #8774 has been updated by jiayp@glodon.com (贾 延平).


I did not write clear,the ".' having the encoding ascii-8bit not
ascii-7bit,so it will be some problem.

Why ruby's default encoding is ascii-8bit not ascii-7bit,will we need
the 8bit in  there some condition?
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41144

Author: jiayp@glodon.com (贾 延平)
Status: Feedback
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
F1d6cc2b735bfd82c8773172da2aeab9?d=identicon&s=25 Nobuyoshi Nakada (nobu)
on 2013-08-14 05:26
(Received via mailing list)
Issue #8774 has been updated by nobu (Nobuyoshi Nakada).


rb_usascii_str_new2() makes a string in US-ASCII, which is 7bit.
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41145

Author: jiayp@glodon.com (贾 延平)
Status: Feedback
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
F1d6cc2b735bfd82c8773172da2aeab9?d=identicon&s=25 Nobuyoshi Nakada (nobu)
on 2013-08-14 05:26
(Received via mailing list)
Issue #8774 has been updated by nobu (Nobuyoshi Nakada).

Status changed from Feedback to Rejected


----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41146

Author: jiayp@glodon.com (贾 延平)
Status: Rejected
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
E5fa308f01c66b3e67773422edf1473a?d=identicon&s=25 "jiayp@glodon.com (贾 延平)" <yanping_jia@hotmail.com (Guest)
on 2013-08-14 07:27
(Received via mailing list)
Issue #8774 has been updated by jiayp@glodon.com (贾 延平).


Yes,you are right,maybe my problem couse by the other reason.
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41147

Author: jiayp@glodon.com (贾 延平)
Status: Rejected
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
8cbb39dadafaf2287a83a13ee4981ec9?d=identicon&s=25 usa (Usaku NAKAMURA) (Guest)
on 2013-09-03 12:33
(Received via mailing list)
Issue #8774 has been updated by usa (Usaku NAKAMURA).

Status changed from Rejected to Open

(reopened. the reason is written at #8789)
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41573

Author: jiayp@glodon.com (贾 延平)
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
E5fa308f01c66b3e67773422edf1473a?d=identicon&s=25 "jiayp@glodon.com (贾 延平)" <yanping_jia@hotmail.com (Guest)
on 2013-09-25 05:25
(Received via mailing list)
Issue #8774 has been updated by jiayp@glodon.com (贾 延平).


Any progress?
----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-41966

Author: jiayp@glodon.com (贾 延平)
Status: Open
Priority: Normal
Assignee:
Category: core
Target version: current: 2.1.0
ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN


When File.dirname()'s value is ".", the value is wrong encoded.
Eabad423977cfc6873b8f5df62b848a6?d=identicon&s=25 unknown (Guest)
on 2014-01-30 05:19
(Received via mailing list)
Issue #8774 has been updated by Hiroshi SHIBATA.

Target version changed from 2.1.0 to current: 2.2.0

----------------------------------------
Bug #8774: rb_file_dirname return wrong encoding string when dir is "."
https://bugs.ruby-lang.org/issues/8774#change-44720

* Author: 贾 延平
* Status: Open
* Priority: Normal
* Assignee:
* Category: core
* Target version: current: 2.2.0
* ruby -v: ruby 2.1.0dev (2013-08-10 trunk 42491) [i386-mingw32]
* Backport: 1.9.3: UNKNOWN, 2.0.0: UNKNOWN
This topic is locked and can not be replied to.