forked from Lainports/freebsd-ports
been triggered by portupgrade which uses finalizers to remove lockfiles. - Fix the bug in URI module that smashed uri paths in merge method for ftp uris. [1] - Fix segmentation fault when cloning objects with dynamically created methods (via instance_eval). [2] PR: ports/131775 [1], ports/135533 [2] Submitted by: Yoshisato YANAGISAWA <osho@pcc-software.org> [2], Helmut Schneider <jumper99@gmx.de> [1], Jaakko Heinonen <jh@saunalahti.fi> [1], Peter Hofer <ph@desktopbsd.net> [1] Obtained from: ruby_1_8 svn tree (rev 22679) [2]
19 lines
439 B
Ruby
19 lines
439 B
Ruby
--- lib/uri/generic.rb.orig 2009-06-18 16:10:22.000000000 +0400
|
|
+++ lib/uri/generic.rb 2009-06-18 16:10:51.000000000 +0400
|
|
@@ -1027,7 +1027,15 @@
|
|
end
|
|
end
|
|
|
|
- str << path_query
|
|
+ path = path_query
|
|
+
|
|
+ #
|
|
+ # Add URI delimiter if the path misses it (like as in FTP)
|
|
+ #
|
|
+ if not path.empty? and not str.empty? and path[0, 1] != '/'
|
|
+ path = '/' + path
|
|
+ end
|
|
+ str << path
|
|
end
|
|
|
|
if @fragment
|