Re: [PATCH v2] rpc: remove trailing whitespace character in error string

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 07/18/2012 09:23 AM, Guannan Ren wrote:
> Instead of only removing the ending newline character, it is
> better to remove all of standard whitespace character for the
> sake of log format.
> 
> One example that we have to do this is:
> After three times incorrect password input, virsh command
> virsh -c qemu://remoteserver/system will report error like:
> 
> : Connection reset by peerey,gssapi-keyex,gssapi-with-mic,password).
> 
> But it should be:
> Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password).
> : Connection reset by peer
> 
> The reason is that we dropped the newline, but have a '\r' left.
> The terminal interprets it as "move the cursor back to the start
> of the current line", so the error string is messed up.

ACK.

-- 
Eric Blake   eblake@xxxxxxxxxx    +1-919-301-3266
Libvirt virtualization library http://libvirt.org



Attachment: signature.asc
Description: OpenPGP digital signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]