bugGNU nano - Bugs: bug #59855, a spell check crashes when using...

 
 

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

bug #59855: a spell check crashes when using --speller=""

Submitter:  Benno Schulenberg <bens>
Submitted:  Mon 11 Jan 2021 02:51:19 PM UTC
   
 
Severity:  3 - Normal Status:  Fixed
Assigned to:  bens Open/Closed:  Closed

Fri 15 Jan 2021 10:55:11 AM UTC, comment #4: 

Released in nano-5.5.

Benno Schulenberg <bens>
Group administrator
Mon 11 Jan 2021 06:17:59 PM UTC, comment #3: 

Any leading whitespace in the speller command now gets stripped, by commit 735a608e.

Benno Schulenberg <bens>
Group administrator
Mon 11 Jan 2021 04:04:45 PM UTC, comment #2: 

Well, nano still crashes when using for example --speller="  ".  :/

Benno Schulenberg <bens>
Group administrator
Mon 11 Jan 2021 03:08:31 PM UTC, comment #1: 

Fixed in git, commit 9266fa66, by calling an external spell checker only when 'alt_speller' is not empty (besides not being NULL).

Benno Schulenberg <bens>
Group administrator
Mon 11 Jan 2021 02:51:19 PM UTC, original submission:  

To reproduce, run 'src/nano --ignore --speller="" NEWS',
and type: ^T ^T.  Result: nano crashes.

Bug existed since version 2.9.6.  The offending commit is 94347f08: "memory: use a reallocation to reduce the amount of leakage".

Found because of a report by Mike Frysinger in bug #59854.

This is the output when running the recipe in valgrind:

==31740== Invalid write of size 8
==31740==    at 0x12C53A: construct_argument_list (text.c:2043)
==31740==    by 0x12C6FD: treat (text.c:2121)
==31740==    by 0x12D3DD: do_spell (text.c:2537)
==31740==    by 0x121B8F: do_statusbar_input (prompt.c:355)
==31740==    by 0x122162: acquire_an_answer (prompt.c:465)
==31740==    by 0x122574: do_prompt (prompt.c:608)
==31740==    by 0x115E39: do_insertfile (files.c:1150)
==31740==    by 0x120F6B: process_a_keystroke (nano.c:1625)
==31740==    by 0x10E0EF: main (nano.c:2544)
==31740==  Address 0x0 is not stack'd, malloc'd or (recently) free'd

Benno Schulenberg <bens>
Group administrator

 

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

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)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-01-15 bens Open/ClosedOpen Closed
    2021-01-11 bens StatusIn Progress Fixed
    2021-01-11 bens StatusFixed In Progress
    2021-01-11 bens StatusIn Progress Fixed

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code