GNU nano - Bugs: bug #60902, "Out of curses" message...
You are not allowed to post comments on this tracker with your current authentication level.
bug #60902: "Out of curses" message when killing multiple nanos
Submitter: | Julian Rosen <jules183> | ||
Submitted: | Sat 10 Jul 2021 03:52:04 AM UTC | ||
Severity: | 2 - Minor | Status: | Fixed |
Assigned to: | bens | Open/Closed: | Closed |
Jump to the original submission
Thu 07 Oct 2021 07:31:37 AM UTC, comment #10: |
Benno Schulenberg <bens> |
Wed 14 Jul 2021 08:47:21 AM UTC, comment #9: The problem of trying to write to the same file is addressed in git, commit e3ef7787, by including nano's PID in the name of the dump file when the buffer is nameless: nano.<pid>.save. |
Benno Schulenberg <bens> |
Tue 13 Jul 2021 07:29:15 AM UTC, comment #8: Thanks for figuring it out and for explaining. Indeed, I kept overlooking that when during write_file() an error occurs ("File exists"), that then the call of statusline() causes a second call of die() ("Out of curses"), which means that get_next_filename() gets called again and now finds a filename that does not conflict, and so the second write_file() succeeds.
|
Benno Schulenberg <bens> |
Mon 12 Jul 2021 05:28:33 PM UTC, comment #7: I don't fully understand what's happening, but here's my partial understanding.
|
Julian Rosen <jules183> |
Mon 12 Jul 2021 03:41:03 PM UTC, comment #6: Nevermind. On the machine with the spinning disk I can now consistently reproduce your original report, with nano-5.4 and without the patch: both nanos say they received a SIGHUP or SIGTERM, one says "Out of curses", and both successfully save the buffer to different dump files. It perplexes me: where does the "Out of curses" come from?
|
Benno Schulenberg <bens> |
Mon 12 Jul 2021 08:08:32 AM UTC, comment #5: Hm! If you undo the patch (with -R), recompile, and then try the recipe with src/nano again, do you then see the "Out of curses" message and the "File exists" message? Or do you see just one "Out of curses" message and both buffers are written? I wonder, because I don't see how the latter could be possible: if there is an "Out of curses" message, then there was some error; if there is some error, then write_file() returns FALSE, and "buffer not written" plus the error message will be reported. |
Benno Schulenberg <bens> |
Sun 11 Jul 2021 05:12:22 PM UTC, comment #4: Repeating the experiment with the version built using your patch: one instance of nano writes its buffer, but the other says
|
Julian Rosen <jules183> |
Sun 11 Jul 2021 08:15:50 AM UTC, comment #3: Hm, okay. Both nanos successfully dump the buffer, but one of them additionally says "Out of curses". Then I am really curious what that message is that would have been shown on the status bar. Can you build nano from source? If yes, then please download the 5.4 tarball [1] and apply the attached patch (with -p1), configure and compile, and then run your recipe while using src/nano.
|
Benno Schulenberg <bens> |
Sat 10 Jul 2021 04:19:01 PM UTC, comment #2: I do not see a "File exists" message from either nano. Both nanos say "Buffer written...", and afterwards nano.save and nano.save.1 both exist with the correct text. So apart from the out of curses message, everything seems to be working as expected.
|
Julian Rosen <jules183> |
Sat 10 Jul 2021 09:01:52 AM UTC, comment #1: Thanks for reporting, Julian.
|
Benno Schulenberg <bens> |
Sat 10 Jul 2021 03:52:04 AM UTC, original submission:
Running Nano 5.4 under Ubuntu 21.04. In certain cases nano returns the message "Out of curses -- please report a bug". To get this error, I open three terminal windows. In the first two, I navigate to the same directory, open nano (blank new document), and type some text. Then in the third terminal, I run +killall nano+. Both nano instances die. The first instance gives a message
|
Julian Rosen <jules183> |
Depends on the following items: None found
Items that depend on this one: None found
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 6 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2021-10-07 | bens | Open/Closed | Open | Closed | |
2021-07-14 | bens | Status | None | Fixed | |
2021-07-11 | bens | Attached File | - | Added 0001-feedback-print-the-message-on-standard-error-when-th.patch, #51660 | |
2021-07-10 | bens | Severity | 3 - Normal | 2 - Minor | |
Assigned to | None | bens | |||
Summary | Out of curses | "Out of curses" message when killing multiple nanos |
Powered by Savane 3.13-d3ae.
Corresponding source code
The fixes were released in nano-5.9. Thanks for reporting.