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

subversion/tests/libsvn_repos/repos-test.c test failures

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2003-11-15 20:55:33 CET

repos-test.c is failing when built with APR pool debugging, valgrind
indicates that the test is reading free'd memory.

==9079== Invalid read of size 4
==9079== at 0x4026D565: svn_fs_is_revision_root (../svn/subversion/libsvn_fs/tree.c:521)
==9079== by 0x4026CA49: do_retry (../svn/subversion/libsvn_fs/trail.c:226)
==9079== by 0x4026CBAB: svn_fs__retry_txn (../svn/subversion/libsvn_fs/trail.c:284)
==9079== by 0x4027156C: svn_fs_copy (../svn/subversion/libsvn_fs/tree.c:3135)
==9079== by 0x8049C71: dir_deltas (../svn/subversion/tests/libsvn_repos/repos-test.c:240)
==9079== by 0x4023A3E4: do_test_num (../svn/subversion/tests/svn_tests_main.c:153)
==9079== by 0x4023A8FC: main (../svn/subversion/tests/svn_tests_main.c:303)
==9079== by 0x4045B14E: __libc_start_main (in /lib/libc-2.2.5.so)
==9079== by 0x80490B0: (within /home/pm/sw/subversion/obj/subversion/tests/libsvn_repos/.libs/lt-repos-test)
==9079== Address 0x41E16E40 is 8 bytes inside a block of size 160 free'd
==9079== at 0x40028C2A: free (vg_replace_malloc.c:220)
==9079== by 0x403B59C2: pool_clear_debug (apr_pools.c:1425)
==9079== by 0x403B5AC3: apr_pool_destroy_debug (apr_pools.c:1486)
==9079== by 0x403B59DB: pool_clear_debug (apr_pools.c:1407)
==9079== by 0x403B5AC3: apr_pool_destroy_debug (apr_pools.c:1486)
==9079== by 0x403B59DB: pool_clear_debug (apr_pools.c:1407)
==9079== by 0x403B5A4E: apr_pool_clear_debug (apr_pools.c:1460)
==9079== by 0x8049BE7: dir_deltas (../svn/subversion/tests/libsvn_repos/repos-test.c:233)
==9079== by 0x4023A3E4: do_test_num (../svn/subversion/tests/svn_tests_main.c:153)

I'm using this patch to make the tests work, but I'm not sure if it's
the correct thing to do.

Index: subversion/tests/libsvn_repos/repos-test.c
===================================================================
--- subversion/tests/libsvn_repos/repos-test.c (revision 7765)
+++ subversion/tests/libsvn_repos/repos-test.c (working copy)
@@ -114,7 +114,6 @@
               expected_trees[revision_count].num_entries, subpool));
     revision_count++;
   }
- svn_pool_clear (subpool);
 
   /* Make a new txn based on the youngest revision, make some changes,
      and commit those changes (which makes a new youngest
@@ -175,7 +174,6 @@
               expected_trees[revision_count].num_entries, subpool));
     revision_count++;
   }
- svn_pool_clear (subpool);
 
   /* Make a new txn based on the youngest revision, make some changes,
      and commit those changes (which makes a new youngest
@@ -230,7 +228,6 @@
               expected_trees[revision_count].num_entries, subpool));
     revision_count++;
   }
- svn_pool_clear (subpool);
 
   /* Make a new txn based on the youngest revision, make some changes,
      and commit those changes (which makes a new youngest
@@ -286,7 +283,6 @@
               expected_trees[revision_count].num_entries, subpool));
     revision_count++;
   }
- svn_pool_clear (subpool);
 
   /* THE BIG IDEA: Now that we have a collection of revisions, let's
      first make sure that given any two revisions, we can get the
@@ -340,7 +336,6 @@
              transaction...so we'll abort it (good for software, bad
              bad bad for society). */
           svn_error_clear (svn_fs_abort_txn (txn, subpool));
- svn_pool_clear (subpool);
         }
     }
 

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Nov 15 20:56:23 2003

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.