projects
/
xen.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2b989e0
)
xsm: return unlabeled instead of failing with ENOENT in get_page_sid
author
Keir Fraser
<keir.fraser@citrix.com>
Wed, 22 Sep 2010 17:26:01 +0000
(18:26 +0100)
committer
Keir Fraser
<keir.fraser@citrix.com>
Wed, 22 Sep 2010 17:26:01 +0000
(18:26 +0100)
It is better to return an unlabeled SID in the case where dsec is NULL
instead of bailing out with an error.
From: Daniel De Graaf <dgdegra@tycho.nsa.gov>
Signed-off-by: Keir Fraser <Keir.Fraser@eu.citrix.com>
xen/xsm/flask/hooks.c
patch
|
blob
|
history
diff --git
a/xen/xsm/flask/hooks.c
b/xen/xsm/flask/hooks.c
index c58f8d71b6deb177c5f96512218c5960d2a186ad..1b36a9e913f017ce477b21a6146e79e188935827 100644
(file)
--- a/
xen/xsm/flask/hooks.c
+++ b/
xen/xsm/flask/hooks.c
@@
-340,10
+340,7
@@
static int get_page_sid(struct page_info *page, u32 *sid)
default:
/*Pages are implicitly labeled by domain ownership!*/
dsec = d->ssid;
- if (dsec)
- *sid = dsec->sid;
- else
- rc = -ENOENT;
+ *sid = dsec ? dsec->sid : SECINITSID_UNLABELED;
break;
}