Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: No fsync on history file? I lost my history
On 2018-09-23 15:45:17 +0000, Daniel Shahaf wrote:
> Yes, I understand that fflush(3) must be called in order to flush data
> from libc's buffers into kernel buffers, which fsync(2) will later flush
> to disk. My question was whether the fflush() call being added was
> redundant because of the existing call on line 2927. It would be odd
> to have two fflush() calls in a row without fwrite() between them; and
> to have only one of them update lasthist.
Oh sorry I misread your message. The fflush() above isn't sufficient
because it's not called in my case. I don't know when the "if" will be
true but calling two fflush() is better than calling none.
Maybe calling only once above them is better, but this will leave the
fflush() a little far from where it's needed.
On Sun, Sep 23, 2018 at 09:40:19PM +0200, Vincent Lefevre wrote:
> But the first one is in a "if", thus might have not been called. Or
> there is an inconsistency in the conditions, which should be fixed.
What does HFILE_USE_OPTIONS mean? This seems to be unset when zsh exits.
--
Best regards,
lilydjwg
Messages sorted by:
Reverse Date,
Date,
Thread,
Author