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 544790 - FreeBSD: GDM issues CRITICAL warning on harmless issue [patch]
FreeBSD: GDM issues CRITICAL warning on harmless issue [patch]
Status: RESOLVED FIXED
Product: gdm
Classification: Core
Component: general
2.20.x
Other All
: Normal trivial
: ---
Assigned To: GDM maintainers
GDM maintainers
Depends on:
Blocks:
 
 
Reported: 2008-07-26 01:10 UTC by Volker Stolz
Modified: 2008-07-28 08:20 UTC
See Also:
GNOME target: ---
GNOME version: 2.21/2.22



Description Volker Stolz 2008-07-26 01:10:23 UTC
Please describe the problem:
On FreeBSD SIOCGIFFLAGS yields ENXIO for non-IP/non-configured interfaces. GDM (gdmchooser) prints a warning at level CRITICAL to the log, making the user think that there's a problem.

Steps to reproduce:
1. Run XDMCP browser on FreeBSD 7


Actual results:
Syslog shows e.g.:
Jul 25 19:52:31 pc139 gdmchooser[2547]: CRITICAL: Could not get SIOCGIFFLAGS for ^\b
Jul 25 19:52:31 pc139 gdmchooser[2547]: CRITICAL: Could not get SIOCGIFFLAGS for 8^R^C



Expected results:
no warnings in syslog

Does this happen every time?
yes

Other information:
The corresponding ioctl-call should fail silently. Nothing to see here, please move along (why not also print strerror(errno) while we are here?):
--- gui/gdmchooser.c.orig
+++ gui/gdmchooser.c
@@ -727,7 +727,7 @@
 			/* paranoia */
 			ifreq.ifr_name[sizeof (ifreq.ifr_name) - 1] = '\0';
 
-			if (ioctl (sock, SIOCGIFFLAGS, &ifreq) < 0) 
+			if ((ioctl (sock, SIOCGIFFLAGS, &ifreq) < 0) && (errno != ENXIO))
 				gdm_common_error ("Could not get SIOCGIFFLAGS for %s", ifr[i].ifr_name);
 
 			if ((ifreq.ifr_flags & IFF_UP) == 0 ||
Comment 1 Brian Cameron 2008-07-28 08:20:41 UTC
Fixed in 2.20 branch.