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

correct pool usage?

From: Martin Hauner <martin.hauner_at_gmx.net>
Date: Sat, 22 Aug 2009 11:11:42 +0200

Hi,

I have a pool usage question. In libsvn_wc/update_editor.c(make_editor)
the code goes like this:

   /* Construct an edit baton. */
   eb = apr_pcalloc(subpool, sizeof(*eb));
   eb->pool = subpool;

   ...

   SVN_ERR(svn_dirent_get_absolute(&eb->anchor_abspath, anchor,
                                   pool));

   if (svn_path_is_empty(target))
     eb->target_abspath = eb->anchor_abspath;
   else
     eb->target_abspath = svn_dirent_join(eb->anchor_abspath, target,
                                          pool);
   ...

   eb->skipped_trees = apr_hash_make(subpool);
   eb->deleted_trees = apr_hash_make(subpool);

Is there a reason why the dirent calls above do not use subpool if anything else
related to eb is using it?

-- 
Martin
Subcommander 2.0.0 Beta 4 - http://subcommander.tigris.org
a Win32/Unix/MacOSX subversion GUI client & diff/merge tool.
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=462&dsMessageId=2386446
Received on 2009-08-23 10:34:01 CEST

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