PERFORCE change 92358 for review
Todd Miller
millert at FreeBSD.org
Fri Feb 24 14:41:44 PST 2006
http://perforce.freebsd.org/chv.cgi?CH=92358
Change 92358 by millert at millert_g4tower on 2006/02/24 22:32:55
Revert debugging code from last change here that was
unintentionally submitted.
Affected files ...
.. //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.c#33 edit
Differences ...
==== //depot/projects/trustedbsd/sedarwin7/src/sedarwin/sedarwin/sebsd.c#33 (text+ko) ====
@@ -116,8 +116,6 @@
int sebsd_verbose = 0;
-static struct label *last_dead_cred_label, *last_dead_task_label, *last_dead_port_label; // XXX - testing
-
static int slot = 1; /* TBD, dynamic */
#define SLOT(l) ((void *)LABEL_TO_SLOT((l), slot).l_ptr)
@@ -485,24 +483,6 @@
static void
sebsd_destroy_cred_label(struct label *label)
{
- // printk("sebsd_destroy_cred_label(%p)\n", &LABEL_TO_SLOT((label), slot));
- last_dead_cred_label = label;
- sebsd_free (SLOT(label));
- SLOT(label) = NULL;
-}
-
-static void
-sebsd_destroy_task_label(struct label *label)
-{
- last_dead_task_label = label;
- sebsd_free (SLOT(label));
- SLOT(label) = NULL;
-}
-
-static void
-sebsd_destroy_port_label(struct label *label)
-{
- last_dead_port_label = label;
sebsd_free (SLOT(label));
SLOT(label) = NULL;
}
@@ -2363,13 +2343,7 @@
{
struct task_security_struct *task;
- /* XXX - SLOT should not return NULL but there is a signal race */
- /* XXX - this may be fixed... */
- if ((task = SLOT(label)) == NULL) {
- printk("sebsd_externalize_cred_label: SLOT returned NULL!\n");
- printk("label: %p, last_task: %p, last_cred: %p, last_port: %p\n", label, last_dead_task_label, last_dead_cred_label, last_dead_port_label); // XXX
- return (ESRCH);
- }
+ task = SLOT(label);
return (sebsd_externalize_sid(task->sid, element_name, sb));
}
@@ -2665,8 +2639,8 @@
.mpo_destroy = sebsd_destroy,
.mpo_destroy_cred_label = sebsd_destroy_cred_label,
- .mpo_destroy_task_label = sebsd_destroy_task_label,
- .mpo_destroy_port_label = sebsd_destroy_port_label,
+ .mpo_destroy_task_label = sebsd_destroy_cred_label,
+ .mpo_destroy_port_label = sebsd_destroy_cred_label,
.mpo_destroy_vnode_label = sebsd_destroy_vnode_label,
.mpo_destroy_devfsdirent_label = sebsd_destroy_vnode_label,
More information about the trustedbsd-cvs
mailing list