[Bug 205697] vi gets confused and corrupts file being edited

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Tue Dec 29 15:35:49 UTC 2015


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=205697

            Bug ID: 205697
           Summary: vi gets confused and corrupts file being edited
           Product: Base System
           Version: 10.2-RELEASE
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: heikki at suonsivu.net

I was editing a file with vi, and got

Error: ?!: Illegal byte sequence; ?!: WARNING: FILE TRUNCATED.

After this, it refused to save the file.  In middle of the file there was ~ one
one line.  However, any attempt to edit that line caused error 

Error: unable to retrieve line 7

The line could not be removed or edited. 

This is nasty as it destroys the file being edited.

I recovered the file from backup, and I get 

paypal: unmodified: line 1; Conversion error on line 7


I might have missed that error when starting to edit.


This is plain text file.  If vi has some magic for UTF8 or whatever, it should
never go confused, and simply switch locate to C with appropriate warning
message.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list