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

Re: svn_cmdline_printf and errors

From: Branko Čibej <brane_at_xbc.nu>
Date: 2004-05-16 22:13:43 CEST

    $ man printf
    int printf (const char *fmt, ...)
    returns the number of characters written...

I don't see any reason change that.

Peter N. Lundblad wrote:

>As the new functions svn_cmdline_printf, svn_cmdline_fprintf and
>svn_cmdline_fputs are defined, they return an svn_error_t *, but the
>implementation never fails. This is because it uses the fuzzy conversion
>from UTF-8 if the real one fails, and it doesn't check the return value of
>the underlying fputs call.
>IN the current code, non of the printf/fprintf/fputs calls check for
>errors. Ofcourse this is because if they all output to stdout or stderr
>and if that doesn't work, there is not much to do. You can't inform the
>user anyway.
>We could either:
>a) Use SVN_ERR everywhere we call one of the new functions except in
>svn_handle_error. Is this overkill?
>b) Ditch the return value of the new functions in favour of void and
>ignore failures (hoping for SIGPIPE kicking in as we do today).

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun May 16 22:14:22 2004

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.