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-changelog

[Xen-changelog] Add argument-checking assertions to rangeset interfaces.

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Add argument-checking assertions to rangeset interfaces.
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 03 Feb 2006 19:24:07 +0000
Delivery-date: Fri, 03 Feb 2006 19:35:52 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 03382076472cb8bd9cd8e524abe7a49c85d2e70c
# Parent  1987bb42110a44a32c28ea99a5398a96515dcce7
Add argument-checking assertions to rangeset interfaces.

Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>

diff -r 1987bb42110a -r 03382076472c xen/common/rangeset.c
--- a/xen/common/rangeset.c     Thu Feb  2 13:57:18 2006
+++ b/xen/common/rangeset.c     Thu Feb  2 14:09:39 2006
@@ -95,6 +95,8 @@
     struct range *x, *y;
     int rc = 0;
 
+    ASSERT(s <= e);
+
     spin_lock(&r->lock);
 
     x = find_range(r, s);
@@ -161,6 +163,8 @@
     struct range *x, *y, *t;
     int rc = 0;
 
+    ASSERT(s <= e);
+
     spin_lock(&r->lock);
 
     x = find_range(r, s);
@@ -227,6 +231,8 @@
     struct range *x;
     int contains;
 
+    ASSERT(s <= e);
+
     spin_lock(&r->lock);
     x = find_range(r, s);
     contains = (x && (x->e >= e));

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Add argument-checking assertions to rangeset interfaces., Xen patchbot -unstable <=