svn_fs_merge

Function svn_fs_merge 

Source
pub unsafe extern "C" fn svn_fs_merge(
    conflict_p: *mut *const c_char,
    source_root: *mut svn_fs_root_t,
    source_path: *const c_char,
    target_root: *mut svn_fs_root_t,
    target_path: *const c_char,
    ancestor_root: *mut svn_fs_root_t,
    ancestor_path: *const c_char,
    pool: *mut apr_pool_t,
) -> *mut svn_error_t
Expand description

Merge changes between two nodes into a third node.

Given nodes @a source and @a target, and a common ancestor @a ancestor, modify @a target to contain all the changes made between @a ancestor and @a source, as well as the changes made between @a ancestor and @a target. @a target_root must be the root of a transaction, not a revision.

@a source, @a target, and @a ancestor are generally directories; this function recursively merges the directories’ contents. If they are files, this function simply returns an error whenever @a source, @a target, and @a ancestor are all distinct node revisions.

If there are differences between @a ancestor and @a source that conflict with changes between @a ancestor and @a target, this function returns an #SVN_ERR_FS_CONFLICT error.

If the merge is successful, @a target is left in the merged state, and the base root of @a target’s txn is set to the root node of @a source. If an error is returned (whether for conflict or otherwise), @a target is left unaffected.

If @a conflict_p is non-NULL, then: a conflict error sets @a *conflict_p to the name of the node in @a target which couldn’t be merged, otherwise, success sets @a *conflict_p to NULL.

Do any necessary temporary allocation in @a pool.