Return-Path: X-Original-To: apmail-subversion-commits-archive@minotaur.apache.org Delivered-To: apmail-subversion-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 3952517566 for ; Sat, 30 Jan 2016 16:26:54 +0000 (UTC) Received: (qmail 31045 invoked by uid 500); 30 Jan 2016 16:26:51 -0000 Delivered-To: apmail-subversion-commits-archive@subversion.apache.org Received: (qmail 31001 invoked by uid 500); 30 Jan 2016 16:26:51 -0000 Mailing-List: contact commits-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@subversion.apache.org Delivered-To: mailing list commits@subversion.apache.org Received: (qmail 30991 invoked by uid 99); 30 Jan 2016 16:26:51 -0000 Received: from Unknown (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 30 Jan 2016 16:26:51 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 9420BC0A64 for ; Sat, 30 Jan 2016 16:26:50 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.446 X-Spam-Level: X-Spam-Status: No, score=0.446 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RP_MATCHES_RCVD=-0.554] autolearn=disabled Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id Wu4eWRbK3t8v for ; Sat, 30 Jan 2016 16:26:49 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with ESMTP id 86D8D20657 for ; Sat, 30 Jan 2016 16:26:49 +0000 (UTC) Received: from svn01-us-west.apache.org (svn.apache.org [10.41.0.6]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 0690DE0185 for ; Sat, 30 Jan 2016 16:26:49 +0000 (UTC) Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id 064D43A008E for ; Sat, 30 Jan 2016 16:26:49 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1727721 - /subversion/trunk/subversion/libsvn_client/resolved.c Date: Sat, 30 Jan 2016 16:26:48 -0000 To: commits@subversion.apache.org From: stsp@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20160130162649.064D43A008E@svn01-us-west.apache.org> Author: stsp Date: Sat Jan 30 16:26:48 2016 New Revision: 1727721 URL: http://svn.apache.org/viewvc?rev=1727721&view=rev Log: * subversion/libsvn_client/resolved.c (svn_client_conflict_tree_get_resolution_options): Always add an option which allows the user to accept the current working copy state. This option was not added if automated resolution is possible, but it needs to be always available so that '--accept working' can function. Modified: subversion/trunk/subversion/libsvn_client/resolved.c Modified: subversion/trunk/subversion/libsvn_client/resolved.c URL: http://svn.apache.org/viewvc/subversion/trunk/subversion/libsvn_client/resolved.c?rev=1727721&r1=1727720&r2=1727721&view=diff ============================================================================== --- subversion/trunk/subversion/libsvn_client/resolved.c (original) +++ subversion/trunk/subversion/libsvn_client/resolved.c Sat Jan 30 16:26:48 2016 @@ -1049,7 +1049,11 @@ svn_client_conflict_tree_get_resolution_ option = apr_pcalloc(result_pool, sizeof(*option)); option->id = svn_client_conflict_option_merged_text; option->description = _("accept current working copy state"); - /* Override ID and DESCRIPTION in case we can offer automated resolution: */ + option->conflict = conflict; + option->do_resolve_func = resolve_tree_conflict; + APR_ARRAY_PUSH((*options), const svn_client_conflict_option_t *) = option; + + /* Add options which offer automated resolution: */ if (svn_client_conflict_get_operation(conflict) == svn_wc_operation_update || svn_client_conflict_get_operation(conflict) == svn_wc_operation_switch) { @@ -1058,10 +1062,15 @@ svn_client_conflict_tree_get_resolution_ reason = svn_client_conflict_get_local_change(conflict); if (reason == svn_wc_conflict_reason_moved_away) { + option = apr_pcalloc(result_pool, sizeof(*option)); option->id = svn_client_conflict_option_update_move_destination; option->description = _("apply incoming changes to move destination"); + option->conflict = conflict; + option->do_resolve_func = resolve_tree_conflict; + APR_ARRAY_PUSH((*options), const svn_client_conflict_option_t *) = + option; } else if (reason == svn_wc_conflict_reason_deleted || reason == svn_wc_conflict_reason_replaced) @@ -1071,16 +1080,18 @@ svn_client_conflict_tree_get_resolution_ svn_client_conflict_tree_get_victim_node_kind(conflict) == svn_node_dir) { + option = apr_pcalloc(result_pool, sizeof(*option)); option->id = svn_client_conflict_option_update_any_moved_away_children; option->description = _("prepare for updating moved-away children, if any"); + option->conflict = conflict; + option->do_resolve_func = resolve_tree_conflict; + APR_ARRAY_PUSH((*options), const svn_client_conflict_option_t *) = + option; } } } - option->conflict = conflict; - option->do_resolve_func = resolve_tree_conflict; - APR_ARRAY_PUSH((*options), const svn_client_conflict_option_t *) = option; return SVN_NO_ERROR; }