After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 388776 - 2.12.5 BROKEN_POLL misdetection leads to GIOChannel brokenness
2.12.5 BROKEN_POLL misdetection leads to GIOChannel brokenness
Status: RESOLVED DUPLICATE of bug 387260
Product: glib
Classification: Platform
Component: general
2.12.x
Other All
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2006-12-22 22:58 UTC by Kees Cook
Modified: 2006-12-22 23:23 UTC
See Also:
GNOME target: ---
GNOME version: 2.17/2.18


Attachments
example program, exhibiting the behavior (2.95 KB, text/plain)
2006-12-22 23:00 UTC, Kees Cook
Details

Description Kees Cook 2006-12-22 22:58:33 UTC
Please describe the problem:
In glib 2.12.5, the BROKEN_POLL gets set, which causes closed fds to never get G_IO_HUP, instead getting G_IO_IN with a 0-byte read forever.  (2.12.4 doesn't test for this.)

Steps to reproduce:
1. Run attached program on 2.12.5
2. See lack of G_IO_HUP



Actual results:
read_status saw G_IO_IN -- reading
read size: 6
read_status saw G_IO_IN -- reading
read size: 0
read_status saw G_IO_IN -- reading
read size: 0
...

Expected results:
read_status saw G_IO_IN -- reading
read size: 6
read_status saw G_IO_HUP -- quitting

Does this happen every time?
Yes

Other information:
Comment 1 Kees Cook 2006-12-22 23:00:21 UTC
Created attachment 78818 [details]
example program, exhibiting the behavior

Test case attached.
Comment 2 Kees Cook 2006-12-22 23:23:30 UTC
Gah, duplicate of 387260.

http://cvs.gnome.org/viewcvs/glib/configure.in?r1=1.533&r2=1.534

*** This bug has been marked as a duplicate of 387260 ***