From: Chen Gang <gang.chen.5i5j@gmail.com>
To: chet.ramey@case.edu
Cc: Andreas Schwab <schwab@linux-m68k.org>,
palves@redhat.com, gdb-patches@sourceware.org,
binutils@sourceware.org, bug-readline@gnu.org, amodra@gmail.com
Subject: Re: [Bug-readline] [PATCH] readline/histfile.c: Check and retry write() operation in history_truncate_file()
Date: Wed, 25 Jun 2014 22:16:00 -0000 [thread overview]
Message-ID: <53AB4A40.7070009@gmail.com> (raw)
In-Reply-To: <53A840CD.1050205@gmail.com>
And I guess, we can simply bypass this discussion, because the new fix
can process write() well and let history_truncate_file() never return -1.
Thanks.
On 06/23/2014 10:59 PM, Chen Gang wrote:
> On 06/23/2014 09:57 PM, Chet Ramey wrote:
>> On 6/21/14, 10:01 PM, Chen Gang wrote:
>>
>>>> history_truncate_file will never return -1.
>>>>
>>>
>>> Hmm... do you mean:
>>>
>>> "for regular file, write() never return 0, if parameter 'count' > 0?"
>>>
>
> I am not quite sure whether it is true, in my experience, it should be
> true, but I have no any proofs for it (if you have, welcome to supply).
>
> thank.
>
>>> or
>>>
>>> "if write() return 0, can also return 0 to history_truncate_file()?".
>>
>
> For me, if write() could return 0, when it happened, we had to process the
> case within history_truncate_file(), could not only return 0 to indicate
> all things go on well.
>
>
>> Both of those things are true, but neither is what I said above.
>>
>
> If both of those things are not true, what your originally said above
> are not true, either.
>
>
> Thanks.
>
--
Chen Gang
Open share and attitude like air water and life which God blessed
prev parent reply other threads:[~2014-06-25 22:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-11 2:36 Chen Gang
2014-06-18 20:33 ` [Bug-readline] " Chet Ramey
2014-06-19 1:31 ` Chen Gang
2014-06-20 8:58 ` Chen Gang
2014-06-20 21:53 ` Chet Ramey
2014-06-21 2:25 ` Chen Gang
2014-06-21 23:19 ` Chet Ramey
2014-06-22 2:01 ` Chen Gang
2014-06-23 13:57 ` Chet Ramey
2014-06-23 14:59 ` Chen Gang
2014-06-25 22:16 ` Chen Gang [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=53AB4A40.7070009@gmail.com \
--to=gang.chen.5i5j@gmail.com \
--cc=amodra@gmail.com \
--cc=binutils@sourceware.org \
--cc=bug-readline@gnu.org \
--cc=chet.ramey@case.edu \
--cc=gdb-patches@sourceware.org \
--cc=palves@redhat.com \
--cc=schwab@linux-m68k.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox