Author: svn-role
Date: Tue Apr 16 04:00:52 2013
New Revision: 1468302

URL: http://svn.apache.org/r1468302
Log:
Merge r1467597 from trunk:

 * r1467597
   Better error message if authentication fails and -F - was used.
   Justification:
     Nice-to-have usability fix. Explains a side-effect of the new-in-1.8
     interactive prompting default behaviour which could be considered a
     regression from 1.7 (use case now requires --force-interactive).
     See here for details:
     http://subversion.tigris.org/issues/show_bug.cgi?id=3913#desc5
   Votes:
     +1: stsp, pburba, brane

Modified:
    subversion/branches/1.8.x/   (props changed)
    subversion/branches/1.8.x/STATUS
    subversion/branches/1.8.x/subversion/svn/svn.c

Propchange: subversion/branches/1.8.x/
------------------------------------------------------------------------------
  Merged /subversion/trunk:r1467597

Modified: subversion/branches/1.8.x/STATUS
URL: 
http://svn.apache.org/viewvc/subversion/branches/1.8.x/STATUS?rev=1468302&r1=1468301&r2=1468302&view=diff
==============================================================================
--- subversion/branches/1.8.x/STATUS (original)
+++ subversion/branches/1.8.x/STATUS Tue Apr 16 04:00:52 2013
@@ -29,14 +29,3 @@ Veto-blocked changes:
 
 Approved changes:
 =================
-
- * r1467597
-   Better error message if authentication fails and -F - was used.
-   Justification:
-     Nice-to-have usability fix. Explains a side-effect of the new-in-1.8
-     interactive prompting default behaviour which could be considered a
-     regression from 1.7 (use case now requires --force-interactive).
-     See here for details:
-     http://subversion.tigris.org/issues/show_bug.cgi?id=3913#desc5
-   Votes:
-     +1: stsp, pburba, brane

Modified: subversion/branches/1.8.x/subversion/svn/svn.c
URL: 
http://svn.apache.org/viewvc/subversion/branches/1.8.x/subversion/svn/svn.c?rev=1468302&r1=1468301&r2=1468302&view=diff
==============================================================================
--- subversion/branches/1.8.x/subversion/svn/svn.c (original)
+++ subversion/branches/1.8.x/subversion/svn/svn.c Tue Apr 16 04:00:52 2013
@@ -1730,6 +1730,7 @@ sub_main(int argc, const char *argv[], a
   svn_boolean_t interactive_conflicts = FALSE;
   svn_boolean_t force_interactive = FALSE;
   svn_boolean_t use_notifier = TRUE;
+  svn_boolean_t reading_file_from_stdin = FALSE;
   apr_hash_t *changelists;
   apr_hash_t *cfg_hash;
 
@@ -1946,6 +1947,7 @@ sub_main(int argc, const char *argv[], a
         SVN_INT_ERR(svn_utf_cstring_to_utf8(&utf8_opt_arg, opt_arg, pool));
         SVN_INT_ERR(svn_stringbuf_from_file2(&(opt_state.filedata),
                                              utf8_opt_arg, pool));
+        reading_file_from_stdin = (strcmp(utf8_opt_arg, "-") == 0);
         dash_F_arg = opt_arg;
         break;
       case opt_targets:
@@ -2883,6 +2885,12 @@ sub_main(int argc, const char *argv[], a
                                      _("Authentication failed and interactive"
                                        " prompting is disabled; see the"
                                        " --force-interactive option"));
+          if (reading_file_from_stdin)
+            err = svn_error_quick_wrap(err,
+                                       _("Reading file from standard input "
+                                         "because of -F option; this can "
+                                         "interfere with interactive "
+                                         "prompting"));
         }
 
       /* Tell the user about 'svn cleanup' if any error on the stack


Reply via email to