nano-devel
[Top][All Lists]
Advanced

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

Re: [Nano-devel] [PATCH v3] text: set and reset the Modified state corre


From: Brand Huntsman
Subject: Re: [Nano-devel] [PATCH v3] text: set and reset the Modified state correctly when undoing/redoing
Date: Wed, 20 Dec 2017 02:00:39 -0700

On Tue, 19 Dec 2017 19:24:04 +0100
Benno Schulenberg <address@hidden> wrote:

> Unset the "Modified" marker only at the point where the file was last
> saved -- if there is such a point, because it can be missing when the
> undo stack was discarded.
> 
> +     thefile->last_saved = (undo *)0xbeeb;

Wouldn't 0x1 be a better magic number? I know allocations would never happen in 
the lower 64k on a "normal" OS, but it could be possible on a non-standard OS. 
No OS would begin allocations at 0x0 and even if allocating began at 0x1, nano 
would have made numerous permanent allocations before any undo nodes.

Other than that, the patch seems to work fine.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]