bugGNU nano - Bugs: bug #54344, with --autoindent, undoing an...


You are not allowed to post comments on this tracker with your current authentication level.

bug #54344: with --autoindent, undoing an <Enter> does not give the correct file size

Submitted by:  Benno Schulenberg <bens>
Submitted on:  Sat 21 Jul 2018 06:31:23 AM UTC  
Severity:  3 - Normal Status:  Fixed
Assigned to:  Benno Schulenberg <bens> Open/Closed:  Closed

Mon 23 Jul 2018 06:14:15 PM UTC, comment #1: 

Fixed in git, commit c4d09cc2.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Sat 21 Jul 2018 06:31:23 AM UTC, original submission:  

(Original report by Liu Hao: http://lists.gnu.org/archive/html/nano-devel/2018-07/msg00073.html.)

To reproduc, run:

  nano --ignore --auto

and type: <Tab> <Tab> word <Enter> ^C

See how there are now ten characters in the buffer.  This is correct: four tabs, four letter, and two newlines.

Now type: M-U ^C

See how nano now claims there are nine characters in the buffer.  This is wrong because the M-U deleted three characters: two tabs and a newline.

Now type <Backspace> six times, followed by ^C.  Nano now claims that there are three characters left in the buffer, but all that remains is a newline (the automatic newline that nano adds as soon as the first character is typed).

Expected behavior: an M-U should restore the correct file size also when autoindent is in effect.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.


No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by bens (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.




    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-09-10 bens Open/ClosedOpen => Closed
    2018-07-23 bens StatusIn Progress => Fixed
    2018-07-22 bens StatusNone => In Progress
        Assigned toNone => bens

    Back to the top

    Powered by Savane 3.6