Fix compiler warning due to missing function prototype.
[svn.git] / subversion / libsvn_client / resolved.c
blobd069137c307a4f464638e71e171b548ec923d4a1
1 /*
2 * resolved.c: wrapper around wc resolved functionality.
4 * ====================================================================
5 * Copyright (c) 2000-2004 CollabNet. All rights reserved.
7 * This software is licensed as described in the file COPYING, which
8 * you should have received as part of this distribution. The terms
9 * are also available at http://subversion.tigris.org/license-1.html.
10 * If newer versions of this license are posted there, you may use a
11 * newer version instead, at your option.
13 * This software consists of voluntary contributions made by many
14 * individuals. For exact contribution history, see the revision
15 * history and logs, available at http://subversion.tigris.org/.
16 * ====================================================================
19 /* ==================================================================== */
23 /*** Includes. ***/
25 #include "svn_types.h"
26 #include "svn_wc.h"
27 #include "svn_client.h"
28 #include "svn_error.h"
29 #include "client.h"
30 #include "private/svn_wc_private.h"
33 /*** Code. ***/
35 svn_error_t *
36 svn_client_resolved(const char *path,
37 svn_boolean_t recursive,
38 svn_client_ctx_t *ctx,
39 apr_pool_t *pool)
41 svn_depth_t depth = (recursive ? svn_depth_infinity : svn_depth_empty);
42 return svn_client_resolve(path, depth,
43 svn_wc_conflict_choose_merged, ctx, pool);
46 svn_error_t *
47 svn_client_resolve(const char *path,
48 svn_depth_t depth,
49 svn_wc_conflict_choice_t conflict_choice,
50 svn_client_ctx_t *ctx,
51 apr_pool_t *pool)
53 svn_wc_adm_access_t *adm_access;
54 int adm_lock_level = SVN_WC__LEVELS_TO_LOCK_FROM_DEPTH(depth);
56 SVN_ERR(svn_wc_adm_probe_open3(&adm_access, NULL, path, TRUE,
57 adm_lock_level,
58 ctx->cancel_func, ctx->cancel_baton,
59 pool));
61 SVN_ERR(svn_wc_resolved_conflict3(path, adm_access, TRUE, TRUE, depth,
62 conflict_choice,
63 ctx->notify_func2, ctx->notify_baton2,
64 ctx->cancel_func, ctx->cancel_baton,
65 pool));
67 SVN_ERR(svn_wc_adm_close(adm_access));
69 return SVN_NO_ERROR;