Bug 6352 - missing check for NULL pointer in os/access.c
Summary: missing check for NULL pointer in os/access.c
Status: RESOLVED DUPLICATE of bug 5218
Alias: None
Product: xorg
Classification: Unclassified
Component: Server/General (show other bugs)
Version: 7.0.0
Hardware: All Linux (All)
: high normal
Assignee: Xorg Project Team
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-03-23 01:45 UTC by Sascha Hauer
Modified: 2006-03-22 12:58 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Sascha Hauer 2006-03-23 01:45:42 UTC
The xorg server crashes when interfaces are present in the system which
don't have an interface address assigned. ConvertAddr() in os/access.c
needs to check for a NULL pointer in sadr. Possible patch below.

Index: xorg-server-X11R7.0-1.0.1/os/access.c
===================================================================
--- xorg-server-X11R7.0-1.0.1.orig/os/access.c
+++ xorg-server-X11R7.0-1.0.1/os/access.c
@@ -1858,6 +1858,8 @@ ConvertAddr (
 {
     if (*len == 0)
         return (FamilyLocal);
+    if (!saddr)
+        return -1;
     switch (saddr->sa_family)
     {
     case AF_UNSPEC:
Comment 1 Adam Jackson 2006-03-23 07:58:46 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.