Bug 5700

Summary: segfault on linux with ppp interfaces
Product: xorg Reporter: Philipp Rumpf <prumpf>
Component: Server/GeneralAssignee: Xorg Project Team <xorg-team>
Status: RESOLVED DUPLICATE QA Contact:
Severity: minor    
Priority: high    
Version: 7.0.0   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Philipp Rumpf 2006-01-24 10:00:19 UTC
On my linux system, getifaddrs() sometimes returns network interfaces with
ifa_addr = 0.  This causes DefineSelf() in os/access.c to call ConvertAddress
with NULL as its first argument, which then causes a segmentation fault.

The interface in question is a ppp interface with no local IP configured, but
I'm not sure whether this is a Linux/glibc bug or an Xorg one.

Anyway, adding the obvious check (if (ifr->ifa_addr == NULL) continue; in the
for loop at access.c:978) fixes the crash.  I believe that should be included as
a sanity check even if there is a standard that says getifaddrs() shouldn't
return such data.
Comment 1 Alan Coopersmith 2006-01-25 12:16:11 UTC

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

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.