[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: r15154 - in trunk: subversion/bindings/swig/ruby/libsvn_swig_ruby subversion/bindings/swig/ruby/svn subversion/bindings/swig/ruby/test tools/examples tools/hook-scripts

From: David James <james82_at_gmail.com>
Date: 2005-07-05 19:39:29 CEST

On 7/5/05, Kouhei Sutou <kou@cozmixng.org> wrote:
> Could you tell me the result (including error messages) of
> the following script?
>
> require "svn/client"
>
> ctx = Svn::Client::Context.new()
> p ObjectSpace.each_object(Svn::Core::Pool) {}
> GC.start
> p ObjectSpace.each_object(Svn::Core::Pool) {}
> ctx.copy("file:///u/james/g/e.txt","file:///u/james/g/g.txt")
Sure! The results are below.

svn_swig_rb_set_pool:target: 0x401bbfcc
#<Svn::Ext::Client::Svn_client_ctx_t:0x401bbfcc>
#<Svn::Ext::Core::Apr_pool_t:0x401bc0f8>
svn_swig_rb_set_pool:target: 0x401bb1bc
#<SWIG::TYPE_p_svn_auth_baton_t:0x401bb1bc>
#<Svn::Ext::Core::Apr_pool_t:0x401bb25c>
2
2
/h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in
`svn_client_copy': Path 'g.txt' already exists
(Svn::Error::FS_ALREADY_EXISTS)
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in `copy'
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in `copy'
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/client.rb:109:in `copy'
        from e.rb:8
/h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75: [BUG] Segmentation fault
ruby 1.8.3 (2005-06-20) [i686-linux]

zsh: abort ruby e.rb

Notice that the script segfaulted as it was exiting with an exception.
If you take out the GC.start call, it works fine. (I show this below.)

svn_swig_rb_set_pool:target: 0x401bc6d4
#<Svn::Ext::Client::Svn_client_ctx_t:0x401bc6d4>
#<Svn::Ext::Core::Apr_pool_t:0x401bc8a0>
svn_swig_rb_set_pool:target: 0x401bbc98
#<SWIG::TYPE_p_svn_auth_baton_t:0x401bbc98>
#<Svn::Ext::Core::Apr_pool_t:0x401bbe50>
2
2
/h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in
`svn_client_copy': Path 'g.txt' already exists
(Svn::Error::FS_ALREADY_EXISTS)
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in `copy'
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/util.rb:75:in `copy'
        from /h/46/james/lib/ruby/site_ruby/1.8/svn/client.rb:109:in `copy'
        from e.rb:7

-- 
David James -- http://www.cs.toronto.edu/~james
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Jul 5 19:49:51 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.