[CRIU] Re: [PATCH 3/4] pr_perror(): print error at the end of line

Cyrill Gorcunov gorcunov at openvz.org
Mon Jan 30 12:25:01 EST 2012


On Mon, Jan 30, 2012 at 09:18:39PM +0400, Kir Kolyshkin wrote:
> This is a standard convention to print error message (i.e. strerror(errno))
> at the end of line, like this:
> 
> 	Cannot remove file: Permission denied
> 
> So pr_perror is fixed to follow this convention (using GNU extension
> %m helps a lot here). Unfortunately, due to this we have to make
> pr_perror() print a new line character, too, so we had to strip it
> from the all pr_perror() invocations.
> 
> Signed-off-by: Kir Kolyshkin <kir at openvz.org>
> ---

Hi Kir, actually I don't like it, we have a number of pr_ helpers
(the idea in first place was to be similar to pr_ helpers used
 in kernel) so this pr_perror become a special one from the whole
pr_ helpers set in terms of "implicit new line at the end".

Kir, can we somehow bring back "explicit \n" at the end somehow?

p.s.: though, if Pavel prefer new convention I will apply the patch.

	Cyrill


More information about the CRIU mailing list