[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-stable] [Qemu-devel] [PATCH for-2.11] nbd/client: Use error_pr
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-stable] [Qemu-devel] [PATCH for-2.11] nbd/client: Use error_prepend() correctly |
Date: |
Tue, 14 Nov 2017 08:28:37 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) |
Eric Blake <address@hidden> writes:
> On 11/13/2017 11:14 AM, Markus Armbruster wrote:
>> Eric Blake <address@hidden> writes:
>>
>>> When using error prepend(), it is necessary to end with a space
>>> in the format string; otherwise, messages come out incorrectly,
>>> such as when connecting to a socket that hangs up immediately:
>>>
>>> can't open device nbd://localhost:10809/: Failed to read dataUnexpected
>>> end-of-file before all bytes were read
>>>
>
>> Preexisting: inconsistent capitalization (Failed vs. failed).
>>
>> In general, prepend chains looks slightly less ugly when each link
>> starts with a lower case letter. Compare:
>>
>> can't open device nbd://localhost:10809/: failed to read data:
>> unexpected end-of-file before all bytes were read
>> Can't open device nbd://localhost:10809/: Failed to read data:
>> Unexpected end-of-file before all bytes were read
>>
>> Neither message is really good, but the second one is ugly to boot.
>
> A tree-wide search shows that we have no strong preference for
> capitalization or not; but I can do a followup patch for at least NBD
> code to prefer lower-case, and enforce that style in future NBD-related
> patches. Not sure if that followup would be 2.11 material, though.
Tree-wide consistency would take consensus on the new rule, a tree-wide
patch (always a bother) to fix up the code, and a checkpatch patch to
catch regressions. We got bigger fish to fry.
Local consistency is much easier. Maintainer's discretion (here:
yours).
>> Reviewed-by: Markus Armbruster <address@hidden>
>>
>
> Thanks