Checkout Tools
  • last updated 5 hours ago
Constraints: committers
Constraints: files
Constraints: dates

Changeset 873736 is being indexed.

Fix several segfaults in the ctypes python bindings by fixing pool usage

bugs and other typos.

[ In subversion/bindings/ctypes-python/csvn ]


(RemoteRepos._log_func_wrapper): Typo fix for tmp_file parameter.

(RemoteRepos.svnimport): Return commit info in its own pool so that

it doesn't get deleted before the function exits.


(WC.commit): Ditto.

(WC.copy, WC.move, WC.delete): Pass commit info object into

function instead of NULL pointer, per API spec.

(WC._notify_func_wrapper, WC._status_wrapper, WC._info_wrapper,

WC._list_wrapper): Copy arguments into dedicated pool

to ensure it doesn't get deleted.


(Hash.__init__, Hash.__setitem__) Typo fix so items are actually

copied into local pool, as they should be.

Followup to r33540 by fixing our SQLite initialization order.

* subversion/libsvn_subr/sqlite.c

(init_sqlite): Per the sqlite docs, call sqlite3_initialize() after


* notes/http-protocol-v2.txt: evolve this a bit more.
Fix issue #3236, "plaintext-passwords assumes pools live across RA sessions".

Revert API requirements introduced on the

dont-save-plaintext-passwords-by-default branch in r30800.

* subversion/libsvn_subr/ssl_client_cert_pw_providers.c

(svn_auth__ssl_client_cert_pw_file_save_creds_helper): Instead of

expecting a scratch pool that survives across RA sessions, allocate

memory for the user's answer in the same pool as the hash table which

holds the answers.

* subversion/libsvn_subr/simple_providers.c

(svn_auth__simple_save_creds_helper): As above.

* subversion/libsvn_subr/auth.c

(svn_auth_save_credentials): Restore pre-r30800 behaviour: Pass a

short-lived scratch pool, instead of a long-lived pool, to the

save_credentials callback.

* subversion/include/svn_auth.h

(svn_auth_provider_t): Remove pool lifetime requirement for

save_credentials callback.



svn_auth_save_credentials): Remove pool lifetime requirement.

Suggested by: gstein

(That is, he suggested how to fix this issue properly, thanks!)

Update definitions of BASE/WORKING/ACTUAL trees after discussion, and

add a note about EOL-style and keyword-expanded format.

* notes/wc-ng-design


On the fs-rep-sharing branch:

Include the FSFS rep cache as part of hotcopy.

* subversion/libsvn_fs_fs/fs_fs.c

(svn_fs_fs__hotcopy): Copy the rep cache.

* subversion/libsvn_fs_fs/rep-cache.c

(REP_CACHE_DB_NAME): Remove from here...

* subversion/libsvn_fs_fs/rep-cache.h

(REP_CACHE_DB_NAME): ...and place here (for hotcopy).

Remove the use of a deprecated API by "unrolling" the code into the

recursive call sequence.

* subversion/libsvn_wc/adm_ops.c:

(process_committed_internal): replace svn_wc_process_committed4() call

with a recursion to self, along with appropriate log handling.

On the fs-rep-sharing branch:

* subversion/libsvn_fs_fs/rep-cache.h:

Remove obsolete comment.

On the fs-rep-sharing branch:

Bring up-to-date with trunk.

  1. … 102 more files in changeset.
On the fs-rep-sharing branch:

Fix blame tests 10 and 11 for FSFS. We accomplish this by introducing a reuse

count as part of the representation key, and incrementing it when we reuse a

node. This ensures that svn_fs_contents_changed() maintains it's original

pre-sharing semantics.

* subversion/libsvn_fs_fs/fs_fs.c

(read_rep_offsets): Parse the reuse count.

(representation_string): Write the reuse count.

(svn_fs_fs__noderev_same_rep_key): Compare reuse counts.

(rep_write_contents_close): If we've found a similar representation,

increment the reuse count.

* subversion/libsvn_fs_fs/fs.h

(representation_t): Add reuse_count parameter.

* subversion/libsvn_fs_fs/rep-cache.c

(upgrade_sql): Add the reuse_count column.

(svn_fs_fs__set_rep_reference): Set the reuse_count column to 0 initially.

(svn_fs_fs__inc_rep_reuse): New.

* subversion/libsvn_fs_fs/rep-cache.h

(svn_fs_fs__inc_rep_reuse): New.

On the fs-rep-sharing branch:

Bump the FSFS format number, because we're fixin' to make some incompatible


* subversion/libsvn_fs_fs/fs_fs.c

(upgrade_body): Preserve the sharded nature of the filesystem while upgrading.

* subversion/libsvn_fs_fs/fs.h



Fix up the new window-test.

* subversion/tests/libsvn_delta/window-test.c:

(stream_window_test): replicate the first 109 bytes only 999 times, not

1000 (to avoid a stack smash). add an svn_checksum_match() test to

actually fail in case of a problem. add an SVN_ERR just in case a

cosmic ray causes svn_checksum() to fail.

On the fs-pack branch:

Bump the FSFS format number to support packing.

* subversion/libsvn_fs_fs/fs_fs.c

(svn_fs_fs__pack): Check the format number to ensure the FS is new enough to

use packing.

* subversion/libsvn_fs_fs/fs.h



On the fs-pack branch:

If we aren't using FSFS sharding, just quit with a no op.

* subversion/libsvn_fs_fs/fs_fs.c,


(svn_fs_fs__pack): New.

* subversion/libsvn_fs_fs/fs.c

(fs_pack): Remove.

(library_vtable): Replace fs_pack() with svn_fs_fs__pack().

On the fs-pack branch:

* subversion/svnadmin/main.c

(cmd_table): Fix copy-pasto.

Tweak a tree conflict UI string.

* subversion/svn/info-cmd.c

(print_info): Change the heading "Tree conflicts:" from plural to singular

as it can now be followed by only one conflict.

Add the supporting function calls to support 'svnadmin pack'.

* subversion/libsvn_fs/fs-loader.h

(fs_library_vtable_t.pack): New.

* subversion/libsvn_fs/fs-loader.c

(svn_fs_pack): New.

* subversion/libsvn_fs_base/fs.c

(base_bdb_pack): New.

(library_vtable): Add pack pointer.

* subversion/svnadmin/main.c

(subcommand_pack): New.

(cmd_table): Add 'pack' subcommand.

* subversion/include/svn_fs.h

(svn_fs_pack): New.

* subversion/include/svn_repos.h

(svn_repos_fs_pack): New.

* subversion/libsvn_repos/fs-wrap.c

(svn_repos_fs_pack): New.

* subversion/libsvn_fs_fs/fs.c

(fs_pack): New.

(library_vtable): Add fs_pack.

    • ?
* STATUS (r33641): Add r33644 and vote for both.
Following up to r33641, fix the other uses of svn_path_join() in 'merge.c'.

Not done by: kfogel

(He blames Emacs.)

* subversion/libsvn_client/merge.c

(filter_self_referential_mergeinfo, populate_remaining_ranges,

combine_range_with_segments, svn_client_merge3):

Use svn_path_url_add_component() instead of svn_path_join(). Remove

inline calls to svn_path_uri_encode().

Create the fsfs-pack branch to experiment with a few ideas about decreasing

inode usage in fsfs.

* STATUS: Nominate and vote for r33641.

Another path->url conversion fix, similar to r33121 and friends:

* subversion/libsvn_client/merge.c

(calculate_left_hand_side): Use svn_path_url_add_component, instead

of svn_path_join, to extend a url by a path component

Found by: Purple Streak <mrpurplestreak{_AT_}>

(Scripted up a good reproduction recipe when requested.)

Fix warning about not being able to find svn_private_config.h when

running Follow-up to r33610.

* build/generator/ Add path to SWIG_INCLUDES so SWIG can better

find svn_private_config.h.

* subversion/bindings/swig/core.i: Changed path to svn_private_config.h since

it can now be found via SWIG_INCLUDES.

* subversion/libsvn_subr/sqlite.c

(init_sqlite): A"void" a warning from some compilers about how the

function declaration isn't a prototype.

* subversion/svn/tree-conflicts.c

(svn_cl__append_human_readable_tree_conflict_description): Print the

victim path in 'Invalid tree conflict data' error message.

* subversion/svn/tree-conflicts.c

(new_tree_conflict_phrases): Consistently align multi-line

strings. Whitespace-only change.

* subversion/svn/tree-conflicts

(tree_conflict_phrases): Rename members 'does_not_exist_update'

and 'does_not_exist_merge' to 'missing_update' and 'missing_merge',

respectively. This way, the phrases are named more similarly

to their corresponding reason svn_wc_conflict_reason_missing.

(new_tree_conflict_phrases, select_our_phrase): Track renames.

Fix issue #3297, "tree conflict data in entries not always printable".

When printing human-readable descriptions of tree conflicts, do not

make any assumptions about valid conflict scenarios. Rather, make

sure to return a usable string in every possible scenario.

* subversion/svn/tree-conflicts.c

(tree_conflict_phrases): Add new members 'update_added', 'we_added',

and 'unversioned'.

(new_tree_conflict_phrases): Initialise new tree_conflict_phrases members.

(select_their_phrase): Handle previously unhandled action 'added' with


(select_our_phrase): Handle previously unhandled reasons 'obstructed' with

update, 'added' with update, and 'unversioned' with both update and merge.

Also fix a bug -- we were returning the wrong string for the 'added'

reason with merge.

(svn_cl__append_tree_conflict_info_xml): Handle previously unhandled

action 'added' and reason 'unversioned' with both update and merge.

Cleanup for r33620.

* subversion/svn/info-cmd.c

(print_info_xml): Remove a comment that no longer applies. Mark an output

string for translation.

(print_info): Mark an output string for translation.

Suggested by: arfrever

Approved by: julianfoad

* subversion/svn/tree-conflicts.c

(select_their_phrase, select_our_phrase): Remove 'default' cases when

switching over values of types svn_wc_conflict_action_t and

svn_wc_conflict_reason_t. Also, instead of returning NULL in

several cases, just make those cases break to a single 'return NULL'

at the end. No functional change.

This commit introduces a warning, which illuminates issue #3297,

"tree conflict data in entries not always printable":

subversion/svn/tree-conflicts.c: In function `select_their_phrase':

subversion/svn/tree-conflicts.c:112: warning: enumeration value \

`svn_wc_conflict_action_add' not handled in switch

subversion/svn/tree-conflicts.c: In function `select_our_phrase':

subversion/svn/tree-conflicts.c:187: warning: enumeration value \

`svn_wc_conflict_reason_unversioned' not handled in switch

I will fix these warnings (and hence issue #3297) in a follow-up commit.