PERFORCE change 86602 for review

Todd Miller millert at FreeBSD.org
Thu Nov 10 08:39:00 PST 2005


http://perforce.freebsd.org/chv.cgi?CH=86602

Change 86602 by millert at millert_ibook on 2005/11/10 16:38:30

	Make ipctrace work again after some intervening framework changes.

Affected files ...

.. //depot/projects/trustedbsd/sedarwin7/src/ipctrace/ipctrace.c#3 edit

Differences ...

==== //depot/projects/trustedbsd/sedarwin7/src/ipctrace/ipctrace.c#3 (text+ko) ====

@@ -69,7 +69,7 @@
 static void
 ipctrace_init()
 {
-
+	printf("ipctrace:: init\n");
 	tbuf_lock = mutex_alloc(ETAP_MISC_PRINTF);
 	tbuf_size = sizeof(tbuf);
 	tbuf_cur = tbuf;
@@ -151,7 +151,7 @@
  */
 
 static int
-ipctrace_syscall(struct proc *p, int call, void *arg)
+ipctrace_syscall(struct proc *p, int call, void *arg, int *retval)
 {
 	kern_return_t kr;
 	struct ipctrace_call_get out;
@@ -207,7 +207,7 @@
 
 static int
 ipctrace_externalize_label(struct label *l, char *element_name,
-    struct sbuf *sb, int *claimed)
+    struct sbuf *sb)
 {
 	struct ipctrace_label *ll;
 	ll = SLOT(l);
@@ -215,7 +215,6 @@
 	if (ll == NULL || strcmp(element_name, "ipctrace"))
 		return (0);
 
-	(*claimed)++;
 	if (ll->portn >= 0) {
 		if (strcmp(ll->itask, ll->ttask))
 			sbuf_printf(sb, "P:%s:%s:%d", ll->itask, ll->ttask, 
@@ -389,9 +388,12 @@
 	.mpo_execve_will_transition = ipctrace_execve_will_transition
 };
 
+static char *labelnamespaces[] = {"ipctrace"};
 struct mac_policy_conf ipctrace_policy_conf = {
 	"ipctrace",		/* policy name */
 	"IPC Trace Module",	/* full name */
+	labelnamespaces,	/* label namespaces */
+	1,			/* namespace count */
 	&ipctrace_ops,		/* policy operations */
 	0,			/* loadtime flags*/
 	&ipctrace_slot,		/* security field */


More information about the p4-projects mailing list