bugGNU Screen - Bugs: bug #67567, 10s timeout during windows...

 
 

bug #67567: 10s timeout during windows closerue on Solaris

Submitter:  Petr Sumbera <psumbera>
Submitted:  Thu 02 Oct 2025 09:35:24 AM UTC
   
 
Category:  Program Logic Severity:  3 - Normal
Priority:  * 5 - Normal Status:  Works For Me
Privacy:  Public Assigned to:  None
Open/Closed:  Open Release:  5.0.1
Fixed Release:  None Planned Release:  None
Work Required:  None
* Mandatory Fields

Post a Comment

Add a New Comment Rich Markup
   

Discussion

Fri 03 Oct 2025 12:20:31 PM UTC, comment #5: 

I can confirm that those 10s comes from SetTimeout() in screen.c.

Petr Sumbera <psumbera>
Fri 03 Oct 2025 11:45:14 AM UTC, comment #4: 

and (more likely) bug #27061

Geraint Edwards <gedge>
Fri 03 Oct 2025 11:43:02 AM UTC, comment #3: 

May be related to bug #47493

Geraint Edwards <gedge>
Fri 03 Oct 2025 07:26:52 AM UTC, comment #2: 

You are right. I don't see it on Linux.

I also don't see it when I run it using truss...

truss -afeo truss.log screen

Petr Sumbera <psumbera>
Thu 02 Oct 2025 06:35:26 PM UTC, comment #1: 

There is no timeout on GNU/Linux.
Can you reproduce it on some other OS (like *BSD or GNU/Linux)?

Alexander Naumov <anaumov>
Group administrator
Thu 02 Oct 2025 09:35:24 AM UTC, original submission:  

Tested on Solaris 11.4:

screen
<return>
<ctrl>-a c
<ctrl>-d
<ctrl>-d
# it waits for cca 10s before it exits

---

I was able to bisect first bad revision:

https://cgit.git. ... d93cd4d0bd50429a1

---

When I completely revert the commit, there is no longer the problem:

--- screen-5.0.1/window.c
+++ screen-5.0.1/window.c
@@ -1505,7 +1505,7 @@ WriteString(p, p->w_outbuf, len);
                return;
        }
 
-       if ((len = read(event->fd, buf, size)) <= 0) {
+       if ((len = read(event->fd, buf, size)) < 0) {
                if (errno == EINTR || errno == EAGAIN)
                        return;
 #if defined(EWOULDBLOCK) && (EWOULDBLOCK != EAGAIN)
@@ -1527,6 +1527,10 @@ bp++;
                len--;
        }
 #endif
+       if (len == 0) {
+               WindowDied(p, 0, 0);
+               return;
+       }
 #ifdef ENABLE_TELNET
        if (p->w_type == W_TYPE_TELNET)
                len = TelIn(p, bp, len, buf + ARRAY_SIZE(buf) - (bp + len));

Petr Sumbera <psumbera>

 

Attached Files

This item currently has no attached files.

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

Attach Files:
   
   
Comment:
   

 

Dependencies

This item does not depend on any other items.

No items depend on this one.

 

Mail Notification Carbon-Copy List

Carbon-Copy List
  • -email is unavailable- added by gedge (Posted a comment)
  • -email is unavailable- added by anaumov (Posted a comment)
  • -email is unavailable- added by psumbera (Submitted the item)
  •  

    Votes

    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.

    Only logged-in users can vote.

     

    History

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2025-10-03 anaumov Summary10s timeout during windows closerue 10s timeout during windows closerue on Solaris
    2025-10-02 anaumov StatusNone Works For Me

    Back to the top

    Powered by Savane 3.16-11ef.
    Corresponding source code