[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] issue #897: libsvn_client

From: Branko Čibej <brane_at_xbc.nu>
Date: 2003-11-06 01:04:54 CET

Erik Huelsmann wrote:

>Hi!
>
>My first revision of a patch for libsvn_client cf issue 897.
>
>Comments?
>
>
There are a few more things that could be done for consistency.

    * Qotes within error messages: '%s' vs. \"%s\". I think we meant to
      standardise on single quotes.
    * Message texts
          o Close-file errors: "Failed to close file '%s'" vs. "Error
            closing file '%s'"
          o Unversioned resource errors: "'%s' is not under version
            control" vs. "'%s' not under version control" vs. "'%s' is
            not versioned". And we seem to be using two different error
            codes for these, SVN_ERR_WC_PATH_NOT_FOUND and
            SVN_ERR_ENTRY_NOT_FOUND

I don't know if fixing these inconsistencies was what you intended.

>Index: subversion/libsvn_client/export.c
>===================================================================
>--- subversion/libsvn_client/export.c (revision 7644)
>+++ subversion/libsvn_client/export.c (working copy)
>@@ -513,7 +513,7 @@
>
> apr_err = apr_file_close (fb->tmp_file);
> if (apr_err)
>- return svn_error_createf (apr_err, NULL, "error closing file '%s'",
>+ return svn_error_createf (apr_err, NULL, "Error closing file '%s'",
> fb->tmppath);
>
> if (text_checksum)
>@@ -525,7 +525,7 @@
> {
> return svn_error_createf
> (SVN_ERR_CHECKSUM_MISMATCH, NULL,
>- "close_file: checksum mismatch for resulting fulltext\n"
>+ "Checksum mismatch for resulting fulltext\n"
> "(%s):\n"
> " expected checksum: %s\n"
> " actual checksum: %s\n",
>
>
We shouldn't have multi-line error messages. They may be marginally
acceptable for the command-line client, but play badly with GUI clients.
Instead, we should create a chain of (wrapped) errors with the same
error code, but different message text.

-- 
Brane Čibej   <brane_at_xbc.nu>   http://www.xbc.nu/brane/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Nov 6 01:05:38 2003

This is an archived mail posted to the Subversion Dev mailing list.