You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by st...@apache.org on 2017/07/31 16:30:35 UTC
svn commit: r1803553 -
/subversion/branches/addremove/subversion/libsvn_client/addremove.c
Author: stsp
Date: Mon Jul 31 16:30:35 2017
New Revision: 1803553
URL: http://svn.apache.org/viewvc?rev=1803553&view=rev
Log:
On the addremove branch: Add magic support.
* subversion/libsvn_client/addremove.c
(addremove): Initialize a magic cookie and pass it on to
svn_client__add_file() and svn_client__add_dir_recursive().
Modified:
subversion/branches/addremove/subversion/libsvn_client/addremove.c
Modified: subversion/branches/addremove/subversion/libsvn_client/addremove.c
URL: http://svn.apache.org/viewvc/subversion/branches/addremove/subversion/libsvn_client/addremove.c?rev=1803553&r1=1803552&r2=1803553&view=diff
==============================================================================
--- subversion/branches/addremove/subversion/libsvn_client/addremove.c (original)
+++ subversion/branches/addremove/subversion/libsvn_client/addremove.c Mon Jul 31 16:30:35 2017
@@ -38,6 +38,7 @@
#include "private/svn_client_private.h"
#include "private/svn_wc_private.h"
+#include "private/svn_magic.h"
#include "svn_private_config.h"
@@ -95,10 +96,13 @@ static svn_error_t *
addremove(const char *local_abspath, svn_depth_t depth,
svn_client_ctx_t *ctx, apr_pool_t *scratch_pool)
{
+ svn_magic__cookie_t *magic_cookie;
struct addremove_status_baton b;
apr_hash_index_t *hi;
apr_pool_t *iterpool;
+ SVN_ERR(svn_magic__init(&magic_cookie, ctx->config, scratch_pool));
+
b.missing = apr_hash_make(scratch_pool);
b.unversioned = apr_hash_make(scratch_pool);
@@ -123,7 +127,7 @@ addremove(const char *local_abspath, svn
if (kind_on_disk == svn_node_file)
{
SVN_ERR(svn_client__add_file(unversioned_abspath,
- NULL, /* TODO: magic cookie */
+ magic_cookie,
NULL, /* TODO: autoprops */
TRUE, /* TODO: !no_autoprops */
ctx, iterpool));
@@ -139,7 +143,7 @@ addremove(const char *local_abspath, svn
unversioned_abspath, depth_below_here,
FALSE, /* force */
TRUE, /* TODO: !no_autoprops */
- NULL, /* TODO: magic cookie */
+ magic_cookie,
NULL, /* TODO: autoprops */
FALSE, /* TODO: refresh_ignores */
NULL, /* TODO: ignores */