Skip to main content

svn_io_run_diff3_3

Function svn_io_run_diff3_3 

Source
pub unsafe extern "C" fn svn_io_run_diff3_3(
    exitcode: *mut c_int,
    dir: *const c_char,
    mine: *const c_char,
    older: *const c_char,
    yours: *const c_char,
    mine_label: *const c_char,
    older_label: *const c_char,
    yours_label: *const c_char,
    merged: *mut apr_file_t,
    diff3_cmd: *const c_char,
    user_args: *const apr_array_header_t,
    pool: *mut apr_pool_t,
) -> *mut svn_error_t
Expand description

Invoke the configured @c diff3 program, in utf8-encoded @a dir like this:

     diff3 -E -m @a mine @a older @a yours > @a merged

(See the diff3 documentation for details.)

If @a user_args is non-NULL, replace “-E” with the const char* elements that @a user_args contains.

@a mine, @a older and @a yours are utf8-encoded paths (relative to @a dir or absolute) to three files that already exist.

@a merged is an open file handle, and is left open after the merge result is written to it. (@a merged should not be the same file as @a mine, or nondeterministic things may happen!)

@a mine_label, @a older_label, @a yours_label are utf8-encoded label parameters for diff3’s -L option. Any of them may be @c NULL, in which case the corresponding @a mine, @a older, or @a yours parameter is used instead.

Set @a *exitcode to diff3’s exit status. If @a *exitcode is anything other than 0 or 1, then return #SVN_ERR_EXTERNAL_PROGRAM. (Note the following from the diff3 info pages: “An exit status of 0 means `diff3’ was successful, 1 means some conflicts were found, and 2 means trouble.”)

@a diff3_cmd must be non-NULL.

Do all allocation in @a pool.

@since New in 1.4.