bugGNU nano - Bugs: bug #52474, linter can mutilate file when mark...

 
 

bug #52474: linter can mutilate file when mark is on

Submitted by:  Benno Schulenberg <bens>
Submitted on:  Tue 21 Nov 2017 08:07:43 PM UTC  
 
Severity: 3 - NormalStatus: Fixed
Assigned to: Benno Schulenberg <bens>Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 21 Nov 2017 08:22:40 PM UTC, comment #1:

Fixed in git, commit c42489d9.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Tue 21 Nov 2017 08:07:43 PM UTC, original submission:

To reproduce, put 'extendsyntax c linter gcc -fshow-column' in your nanorc, and run:

src/nano +1234 src/text.c

Then type: M-A xxx <Down> <Down> <Down> ^T Y.

(Notice that after saving, the title continues to say "Modified". Strange. Also notice how nearly the whole edit window is highlighted. :| )

Then type: ^C ^X N.

Now look at the src/text.c file -- or do a 'git diff'. Wow! The whole file was deleted! Only the bit that was highlighted remains.

Expected behavior: the linter saves the whole buffer, even when a part is highlighted. And the linter switches the mark off while showing the places that error messages refer to. And better: it leaves the mark off, because when the user exits from the linter (^C), most likely the cursor is somewhere else entirely, and the highlighted stuff will be kind of random, useless.

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

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

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

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Tue 28 Nov 2017 08:12:32 PM UTCbensOpen/ClosedOpen=>Closed
    Tue 21 Nov 2017 08:22:40 PM UTCbensStatusIn Progress=>Fixed

    Back to the top


    Powered by Savane 3.1-cleanup1