WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

[Xen-devel] [PATCH] avoid NULL pointer dereference.

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] avoid NULL pointer dereference.
From: Tony Breeds <tony@xxxxxxxxxxxxxxxxxx>
Date: Thu, 24 Nov 2005 15:48:30 +1100
Delivery-date: Thu, 24 Nov 2005 04:48:38 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Mail-followup-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.9i
Hi All,
        xen/common/acm_ops.c, check for a NULL pointer and then
cheerfully dereferences it.

Signed-off-by: Tony Breeds <tony@xxxxxxxxxxxxxxxxxx>

diff -r 4b6e8661fe2b xen/common/acm_ops.c
--- a/xen/common/acm_ops.c      Thu Nov 24 01:32:39 2005
+++ b/xen/common/acm_ops.c      Thu Nov 24 15:45:57 2005
@@ -172,7 +172,7 @@
             }
             if (subj->ssid == NULL) {
                 put_domain(subj);
-                ret = -ESRCH;
+                return -ESRCH;
             }
             ssidref1 = ((struct acm_ssid_domain *)(subj->ssid))->ssidref;
             put_domain(subj);

Yours Tony

   linux.conf.au       http://linux.conf.au/ || http://lca2006.linux.org.au/
   Jan 23-28 2006      The Australian Linux Technical Conference!


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>