e1e36a0
diff --exclude-from=exclude -N -u -r nsalibselinux/include/selinux/av_permissions.h libselinux-2.0.46/include/selinux/av_permissions.h
c4aa29e
--- nsalibselinux/include/selinux/av_permissions.h	2007-11-15 15:52:46.000000000 -0500
e1e36a0
+++ libselinux-2.0.46/include/selinux/av_permissions.h	2008-01-03 15:23:31.000000000 -0500
c4aa29e
@@ -900,6 +900,8 @@
c4aa29e
 #define PACKET__SEND                              0x00000001UL
c4aa29e
 #define PACKET__RECV                              0x00000002UL
c4aa29e
 #define PACKET__RELABELTO                         0x00000004UL
c4aa29e
+#define PACKET__FLOW_IN                           0x00000008UL
c4aa29e
+#define PACKET__FLOW_OUT                          0x00000010UL
c4aa29e
 #define KEY__VIEW                                 0x00000001UL
c4aa29e
 #define KEY__READ                                 0x00000002UL
c4aa29e
 #define KEY__WRITE                                0x00000004UL
e1e36a0
diff --exclude-from=exclude -N -u -r nsalibselinux/src/Makefile libselinux-2.0.46/src/Makefile
e1e36a0
--- nsalibselinux/src/Makefile	2007-09-26 19:37:45.000000000 -0400
8054023
+++ libselinux-2.0.46/src/Makefile	2008-01-05 08:19:27.000000000 -0500
e1e36a0
@@ -77,14 +77,14 @@
e1e36a0
 
e1e36a0
 install: all 
e1e36a0
 	test -d $(LIBDIR) || install -m 755 -d $(LIBDIR)
e1e36a0
-	install -m 644 $(LIBA) $(LIBDIR)
e1e36a0
 	test -d $(SHLIBDIR) || install -m 755 -d $(SHLIBDIR)
e1e36a0
 	install -m 755 $(LIBSO) $(SHLIBDIR)
e1e36a0
 	cd $(LIBDIR) && ln -sf ../../`basename $(SHLIBDIR)`/$(LIBSO) $(TARGET)
e1e36a0
 
e1e36a0
 install-pywrap: pywrap
e1e36a0
 	test -d $(PYTHONLIBDIR)/site-packages || install -m 755 -d $(PYTHONLIBDIR)/site-packages
e1e36a0
-	install -m 755 $(SWIGFILES) $(PYTHONLIBDIR)/site-packages
e1e36a0
+	install -m 755 $(SWIGSO) $(PYTHONLIBDIR)/site-packages
e1e36a0
+	install -m 644  selinux.py $(PYTHONLIBDIR)/site-packages
e1e36a0
 
e1e36a0
 relabel:
e1e36a0
 	/sbin/restorecon $(SHLIBDIR)/$(LIBSO)
e1e36a0
diff --exclude-from=exclude -N -u -r nsalibselinux/src/matchpathcon.c libselinux-2.0.46/src/matchpathcon.c
39606ee
--- nsalibselinux/src/matchpathcon.c	2007-09-28 09:48:58.000000000 -0400
e1e36a0
+++ libselinux-2.0.46/src/matchpathcon.c	2008-01-03 15:23:32.000000000 -0500
71cd138
@@ -2,6 +2,7 @@
71cd138
 #include <string.h>
71cd138
 #include <errno.h>
71cd138
 #include <stdio.h>
71cd138
+#include <syslog.h>
71cd138
 #include "selinux_internal.h"
71cd138
 #include "label_internal.h"
71cd138
 #include "callbacks.h"
0fa749d
@@ -57,7 +58,7 @@
71cd138
 {
71cd138
 	va_list ap;
71cd138
 	va_start(ap, fmt);
71cd138
-	vfprintf(stderr, fmt, ap);
0fa749d
+	vsyslog(LOG_ERR, fmt, ap);
71cd138
 	va_end(ap);
71cd138
 }
71cd138
 
8054023
diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinux.py libselinux-2.0.46/src/selinux.py
8054023
--- nsalibselinux/src/selinux.py	2007-10-05 13:09:54.000000000 -0400
8054023
+++ libselinux-2.0.46/src/selinux.py	2008-01-08 05:00:39.000000000 -0500
8054023
@@ -1,5 +1,5 @@
8054023
 # This file was automatically generated by SWIG (http://www.swig.org).
8054023
-# Version 1.3.31
8054023
+# Version 1.3.33
8054023
 #
8054023
 # Don't modify this file, modify the SWIG interface instead.
8054023
 # This file is compatible with both classic and new-style classes.
8054023
Binary files nsalibselinux/src/selinux.pyc and libselinux-2.0.46/src/selinux.pyc differ
8054023
diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinuxswig.i libselinux-2.0.46/src/selinuxswig.i
8054023
--- nsalibselinux/src/selinuxswig.i	2007-10-01 09:54:35.000000000 -0400
8054023
+++ libselinux-2.0.46/src/selinuxswig.i	2008-01-08 05:00:22.000000000 -0500
8054023
@@ -10,6 +10,7 @@
8054023
 %apply int *OUTPUT { size_t * };
8054023
 
8054023
 %typedef unsigned mode_t;
8054023
+%typedef unsigned pid_t;
8054023
 
8054023
 %typemap(in, numinputs=0) (char ***names, int *len) (char **temp1, int temp2) {
8054023
 	$1 = &temp1;
8054023
diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinuxswig_wrap.c libselinux-2.0.46/src/selinuxswig_wrap.c
8054023
--- nsalibselinux/src/selinuxswig_wrap.c	2007-10-05 13:09:54.000000000 -0400
8054023
+++ libselinux-2.0.46/src/selinuxswig_wrap.c	2008-01-08 05:00:39.000000000 -0500
8054023
@@ -1,6 +1,6 @@
8054023
 /* ----------------------------------------------------------------------------
8054023
  * This file was automatically generated by SWIG (http://www.swig.org).
8054023
- * Version 1.3.31
8054023
+ * Version 1.3.33
8054023
  * 
8054023
  * This file is not intended to be easily readable and contains a number of 
8054023
  * coding conventions designed to improve portability and efficiency. Do not make
8054023
@@ -17,14 +17,14 @@
8054023
 
8054023
 /* template workaround for compilers that cannot correctly implement the C++ standard */
8054023
 #ifndef SWIGTEMPLATEDISAMBIGUATOR
8054023
-# if defined(__SUNPRO_CC)
8054023
-#   if (__SUNPRO_CC <= 0x560)
8054023
-#     define SWIGTEMPLATEDISAMBIGUATOR template
8054023
-#   else
8054023
-#     define SWIGTEMPLATEDISAMBIGUATOR 
8054023
-#   endif
8054023
+# if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
8054023
+#  define SWIGTEMPLATEDISAMBIGUATOR template
8054023
+# elif defined(__HP_aCC)
8054023
+/* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
8054023
+/* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
8054023
+#  define SWIGTEMPLATEDISAMBIGUATOR template
8054023
 # else
8054023
-#   define SWIGTEMPLATEDISAMBIGUATOR 
8054023
+#  define SWIGTEMPLATEDISAMBIGUATOR
8054023
 # endif
8054023
 #endif
8054023
 
8054023
@@ -107,6 +107,12 @@
8054023
 # define _CRT_SECURE_NO_DEPRECATE
8054023
 #endif
8054023
 
8054023
+/* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
8054023
+#if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
8054023
+# define _SCL_SECURE_NO_DEPRECATE
8054023
+#endif
8054023
+
8054023
+
8054023
 
8054023
 /* Python.h has to appear first */
8054023
 #include <Python.h>
8054023
@@ -343,7 +349,7 @@
8054023
     while ((*f2 == ' ') && (f2 != l2)) ++f2;
8054023
     if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
8054023
   }
8054023
-  return (l1 - f1) - (l2 - f2);
8054023
+  return (int)((l1 - f1) - (l2 - f2));
8054023
 }
8054023
 
8054023
 /*
8054023
@@ -1090,14 +1096,14 @@
8054023
 /* Unpack the argument tuple */
8054023
 
8054023
 SWIGINTERN int
8054023
-SWIG_Python_UnpackTuple(PyObject *args, const char *name, int min, int max, PyObject **objs)
8054023
+SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, PyObject **objs)
8054023
 {
8054023
   if (!args) {
8054023
     if (!min && !max) {
8054023
       return 1;
8054023
     } else {
8054023
       PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got none", 
8054023
-		   name, (min == max ? "" : "at least "), min);
8054023
+		   name, (min == max ? "" : "at least "), (int)min);
8054023
       return 0;
8054023
     }
8054023
   }  
8054023
@@ -1105,14 +1111,14 @@
8054023
     PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
8054023
     return 0;
8054023
   } else {
8054023
-    register int l = PyTuple_GET_SIZE(args);
8054023
+    register Py_ssize_t l = PyTuple_GET_SIZE(args);
8054023
     if (l < min) {
8054023
       PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
8054023
-		   name, (min == max ? "" : "at least "), min, l);
8054023
+		   name, (min == max ? "" : "at least "), (int)min, (int)l);
8054023
       return 0;
8054023
     } else if (l > max) {
8054023
       PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
8054023
-		   name, (min == max ? "" : "at most "), max, l);
8054023
+		   name, (min == max ? "" : "at most "), (int)max, (int)l);
8054023
       return 0;
8054023
     } else {
8054023
       register int i;
8054023
@@ -1591,9 +1597,11 @@
8054023
     (unaryfunc)0,                 /*nb_float*/
8054023
     (unaryfunc)PySwigObject_oct,  /*nb_oct*/
8054023
     (unaryfunc)PySwigObject_hex,  /*nb_hex*/
8054023
-#if PY_VERSION_HEX >= 0x02020000
8054023
-    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_true_divide */ 
8054023
-#elif PY_VERSION_HEX >= 0x02000000
8054023
+#if PY_VERSION_HEX >= 0x02050000 /* 2.5.0 */
8054023
+    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */
8054023
+#elif PY_VERSION_HEX >= 0x02020000 /* 2.2.0 */
8054023
+    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_true_divide */
8054023
+#elif PY_VERSION_HEX >= 0x02000000 /* 2.0.0 */
8054023
     0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_or */
8054023
 #endif
8054023
   };
8054023
@@ -2458,14 +2466,13 @@
8054023
 #define SWIGTYPE_p_int swig_types[7]
8054023
 #define SWIGTYPE_p_p_char swig_types[8]
8054023
 #define SWIGTYPE_p_p_p_char swig_types[9]
8054023
-#define SWIGTYPE_p_pid_t swig_types[10]
8054023
-#define SWIGTYPE_p_security_class_mapping swig_types[11]
8054023
-#define SWIGTYPE_p_selinux_callback swig_types[12]
8054023
-#define SWIGTYPE_p_selinux_opt swig_types[13]
8054023
-#define SWIGTYPE_p_unsigned_int swig_types[14]
8054023
-#define SWIGTYPE_p_unsigned_short swig_types[15]
8054023
-static swig_type_info *swig_types[17];
8054023
-static swig_module_info swig_module = {swig_types, 16, 0, 0, 0, 0};
8054023
+#define SWIGTYPE_p_security_class_mapping swig_types[10]
8054023
+#define SWIGTYPE_p_selinux_callback swig_types[11]
8054023
+#define SWIGTYPE_p_selinux_opt swig_types[12]
8054023
+#define SWIGTYPE_p_unsigned_int swig_types[13]
8054023
+#define SWIGTYPE_p_unsigned_short swig_types[14]
8054023
+static swig_type_info *swig_types[16];
8054023
+static swig_module_info swig_module = {swig_types, 15, 0, 0, 0, 0};
8054023
 #define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
8054023
 #define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
8054023
 
8054023
@@ -2484,7 +2491,7 @@
8054023
 
8054023
 #define SWIG_name    "_selinux"
8054023
 
8054023
-#define SWIGVERSION 0x010331 
8054023
+#define SWIGVERSION 0x010333 
8054023
 #define SWIG_VERSION SWIGVERSION
8054023
 
8054023
 
8054023
@@ -2577,14 +2584,12 @@
8054023
 
8054023
 
8054023
 #include <limits.h>
8054023
-#ifndef LLONG_MIN
8054023
-# define LLONG_MIN	LONG_LONG_MIN
8054023
-#endif
8054023
-#ifndef LLONG_MAX
8054023
-# define LLONG_MAX	LONG_LONG_MAX
8054023
-#endif
8054023
-#ifndef ULLONG_MAX
8054023
-# define ULLONG_MAX	ULONG_LONG_MAX
8054023
+#if !defined(SWIG_NO_LLONG_MAX)
8054023
+# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
8054023
+#   define LLONG_MAX __LONG_LONG_MAX__
8054023
+#   define LLONG_MIN (-LLONG_MAX - 1LL)
8054023
+#   define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
8054023
+# endif
8054023
 #endif
8054023
 
8054023
 
8054023
@@ -2669,13 +2674,18 @@
8054023
 
8054023
 
8054023
 SWIGINTERN int
8054023
-SWIG_AsVal_long (PyObject *obj, long* val)
8054023
+SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) 
8054023
 {
8054023
   if (PyInt_Check(obj)) {
8054023
-    if (val) *val = PyInt_AsLong(obj);
8054023
-    return SWIG_OK;
8054023
+    long v = PyInt_AsLong(obj);
8054023
+    if (v >= 0) {
8054023
+      if (val) *val = v;
8054023
+      return SWIG_OK;
8054023
+    } else {
8054023
+      return SWIG_OverflowError;
8054023
+    }
8054023
   } else if (PyLong_Check(obj)) {
8054023
-    long v = PyLong_AsLong(obj);
8054023
+    unsigned long v = PyLong_AsUnsignedLong(obj);
8054023
     if (!PyErr_Occurred()) {
8054023
       if (val) *val = v;
8054023
       return SWIG_OK;
8054023
@@ -2686,7 +2696,7 @@
8054023
 #ifdef SWIG_PYTHON_CAST_MODE
8054023
   {
8054023
     int dispatch = 0;
8054023
-    long v = PyInt_AsLong(obj);
8054023
+    unsigned long v = PyLong_AsUnsignedLong(obj);
8054023
     if (!PyErr_Occurred()) {
8054023
       if (val) *val = v;
8054023
       return SWIG_AddCast(SWIG_OK);
8054023
@@ -2696,8 +2706,8 @@
8054023
     if (!dispatch) {
8054023
       double d;
8054023
       int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d);;
8054023
-      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
8054023
-	if (val) *val = (long)(d);
8054023
+      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) {
8054023
+	if (val) *val = (unsigned long)(d);
8054023
 	return res;
8054023
       }
8054023
     }
8054023
@@ -2708,15 +2718,15 @@
8054023
 
8054023
 
8054023
 SWIGINTERN int
8054023
-SWIG_AsVal_int (PyObject * obj, int *val)
8054023
+SWIG_AsVal_unsigned_SS_int (PyObject * obj, unsigned int *val)
8054023
 {
8054023
-  long v;
8054023
-  int res = SWIG_AsVal_long (obj, &v);
8054023
+  unsigned long v;
8054023
+  int res = SWIG_AsVal_unsigned_SS_long (obj, &v);
8054023
   if (SWIG_IsOK(res)) {
8054023
-    if ((v < INT_MIN || v > INT_MAX)) {
8054023
+    if ((v > UINT_MAX)) {
8054023
       return SWIG_OverflowError;
8054023
     } else {
8054023
-      if (val) *val = (int)(v);
8054023
+      if (val) *val = (unsigned int)(v);
8054023
     }
8054023
   }  
8054023
   return res;
8054023
@@ -2724,18 +2734,13 @@
8054023
 
8054023
 
8054023
 SWIGINTERN int
8054023
-SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) 
8054023
+SWIG_AsVal_long (PyObject *obj, long* val)
8054023
 {
8054023
   if (PyInt_Check(obj)) {
8054023
-    long v = PyInt_AsLong(obj);
8054023
-    if (v >= 0) {
8054023
-      if (val) *val = v;
8054023
-      return SWIG_OK;
8054023
-    } else {
8054023
-      return SWIG_OverflowError;
8054023
-    }
8054023
+    if (val) *val = PyInt_AsLong(obj);
8054023
+    return SWIG_OK;
8054023
   } else if (PyLong_Check(obj)) {
8054023
-    unsigned long v = PyLong_AsUnsignedLong(obj);
8054023
+    long v = PyLong_AsLong(obj);
8054023
     if (!PyErr_Occurred()) {
8054023
       if (val) *val = v;
8054023
       return SWIG_OK;
8054023
@@ -2746,7 +2751,7 @@
8054023
 #ifdef SWIG_PYTHON_CAST_MODE
8054023
   {
8054023
     int dispatch = 0;
8054023
-    unsigned long v = PyLong_AsUnsignedLong(obj);
8054023
+    long v = PyInt_AsLong(obj);
8054023
     if (!PyErr_Occurred()) {
8054023
       if (val) *val = v;
8054023
       return SWIG_AddCast(SWIG_OK);
8054023
@@ -2756,8 +2761,8 @@
8054023
     if (!dispatch) {
8054023
       double d;
8054023
       int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d);;
8054023
-      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) {
8054023
-	if (val) *val = (unsigned long)(d);
8054023
+      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
8054023
+	if (val) *val = (long)(d);
8054023
 	return res;
8054023
       }
8054023
     }
8054023
@@ -2768,15 +2773,15 @@
8054023
 
8054023
 
8054023
 SWIGINTERN int
8054023
-SWIG_AsVal_unsigned_SS_int (PyObject * obj, unsigned int *val)
8054023
+SWIG_AsVal_int (PyObject * obj, int *val)
8054023
 {
8054023
-  unsigned long v;
8054023
-  int res = SWIG_AsVal_unsigned_SS_long (obj, &v);
8054023
+  long v;
8054023
+  int res = SWIG_AsVal_long (obj, &v);
8054023
   if (SWIG_IsOK(res)) {
8054023
-    if ((v > UINT_MAX)) {
8054023
+    if ((v < INT_MIN || v > INT_MAX)) {
8054023
       return SWIG_OverflowError;
8054023
     } else {
8054023
-      if (val) *val = (unsigned int)(v);
8054023
+      if (val) *val = (int)(v);
8054023
     }
8054023
   }  
8054023
   return res;
8054023
@@ -2986,24 +2991,18 @@
8054023
   pid_t arg1 ;
8054023
   security_context_t *arg2 = (security_context_t *) 0 ;
8054023
   int result;
8054023
-  void *argp1 ;
8054023
-  int res1 = 0 ;
8054023
+  unsigned int val1 ;
8054023
+  int ecode1 = 0 ;
8054023
   security_context_t temp2 = 0 ;
8054023
   PyObject * obj0 = 0 ;
8054023
   
8054023
   arg2 = &temp2;
8054023
   if (!PyArg_ParseTuple(args,(char *)"O:getpidcon",&obj0)) SWIG_fail;
8054023
-  {
8054023
-    res1 = SWIG_ConvertPtr(obj0, &argp1, SWIGTYPE_p_pid_t,  0 );
8054023
-    if (!SWIG_IsOK(res1)) {
8054023
-      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "getpidcon" "', argument " "1"" of type '" "pid_t""'"); 
8054023
-    }  
8054023
-    if (!argp1) {
8054023
-      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "getpidcon" "', argument " "1"" of type '" "pid_t""'");
8054023
-    } else {
8054023
-      arg1 = *((pid_t *)(argp1));
8054023
-    }
8054023
-  }
8054023
+  ecode1 = SWIG_AsVal_unsigned_SS_int(obj0, &val1);
8054023
+  if (!SWIG_IsOK(ecode1)) {
8054023
+    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "getpidcon" "', argument " "1"" of type '" "pid_t""'");
8054023
+  } 
8054023
+  arg1 = (pid_t)(val1);
8054023
   result = (int)getpidcon(arg1,arg2);
8054023
   resultobj = SWIG_From_int((int)(result));
8054023
   if (*arg2) {
8054023
@@ -3025,24 +3024,18 @@
8054023
   pid_t arg1 ;
8054023
   security_context_t *arg2 = (security_context_t *) 0 ;
8054023
   int result;
8054023
-  void *argp1 ;
8054023
-  int res1 = 0 ;
8054023
+  unsigned int val1 ;
8054023
+  int ecode1 = 0 ;
8054023
   security_context_t temp2 = 0 ;
8054023
   PyObject * obj0 = 0 ;
8054023
   
8054023
   arg2 = &temp2;
8054023
   if (!PyArg_ParseTuple(args,(char *)"O:getpidcon_raw",&obj0)) SWIG_fail;
8054023
-  {
8054023
-    res1 = SWIG_ConvertPtr(obj0, &argp1, SWIGTYPE_p_pid_t,  0 );
8054023
-    if (!SWIG_IsOK(res1)) {
8054023
-      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "getpidcon_raw" "', argument " "1"" of type '" "pid_t""'"); 
8054023
-    }  
8054023
-    if (!argp1) {
8054023
-      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "getpidcon_raw" "', argument " "1"" of type '" "pid_t""'");
8054023
-    } else {
8054023
-      arg1 = *((pid_t *)(argp1));
8054023
-    }
8054023
-  }
8054023
+  ecode1 = SWIG_AsVal_unsigned_SS_int(obj0, &val1);
8054023
+  if (!SWIG_IsOK(ecode1)) {
8054023
+    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "getpidcon_raw" "', argument " "1"" of type '" "pid_t""'");
8054023
+  } 
8054023
+  arg1 = (pid_t)(val1);
8054023
   result = (int)getpidcon_raw(arg1,arg2);
8054023
   resultobj = SWIG_From_int((int)(result));
8054023
   if (*arg2) {
8054023
@@ -8149,7 +8142,7 @@
8054023
 /* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */
8054023
 
8054023
 static swig_type_info _swigt__p_SELboolean = {"_p_SELboolean", "SELboolean *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_av_decision = {"_p_av_decision", "struct av_decision *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_av_decision = {"_p_av_decision", "struct av_decision *|av_decision *", 0, 0, (void*)0, 0};
8054023
 static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
8054023
 static swig_type_info _swigt__p_f_int_p_q_const__char_v_______int = {"_p_f_int_p_q_const__char_v_______int", "int (*)(int,char const *,...)", 0, 0, (void*)0, 0};
8054023
 static swig_type_info _swigt__p_f_p_p_char__int = {"_p_f_p_p_char__int", "int (*)(char **)|int (*)(security_context_t *)", 0, 0, (void*)0, 0};
8054023
@@ -8158,12 +8151,11 @@
8054023
 static swig_type_info _swigt__p_int = {"_p_int", "int *", 0, 0, (void*)0, 0};
8054023
 static swig_type_info _swigt__p_p_char = {"_p_p_char", "char **|security_context_t *", 0, 0, (void*)0, 0};
8054023
 static swig_type_info _swigt__p_p_p_char = {"_p_p_p_char", "char ***|security_context_t **", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_pid_t = {"_p_pid_t", "pid_t *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_security_class_mapping = {"_p_security_class_mapping", "struct security_class_mapping *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_selinux_callback = {"_p_selinux_callback", "union selinux_callback *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_selinux_opt = {"_p_selinux_opt", "selinux_opt *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "unsigned int *|access_vector_t *", 0, 0, (void*)0, 0};
8054023
-static swig_type_info _swigt__p_unsigned_short = {"_p_unsigned_short", "unsigned short *|security_class_t *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_security_class_mapping = {"_p_security_class_mapping", "struct security_class_mapping *|security_class_mapping *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_selinux_callback = {"_p_selinux_callback", "union selinux_callback *|selinux_callback *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_selinux_opt = {"_p_selinux_opt", "struct selinux_opt *|selinux_opt *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_unsigned_int = {"_p_unsigned_int", "unsigned int *|access_vector_t *|mode_t *|pid_t *", 0, 0, (void*)0, 0};
8054023
+static swig_type_info _swigt__p_unsigned_short = {"_p_unsigned_short", "security_class_t *|unsigned short *", 0, 0, (void*)0, 0};
8054023
 
8054023
 static swig_type_info *swig_type_initial[] = {
8054023
   &_swigt__p_SELboolean,
8054023
@@ -8176,7 +8168,6 @@
8054023
   &_swigt__p_int,
8054023
   &_swigt__p_p_char,
8054023
   &_swigt__p_p_p_char,
8054023
-  &_swigt__p_pid_t,
8054023
   &_swigt__p_security_class_mapping,
8054023
   &_swigt__p_selinux_callback,
8054023
   &_swigt__p_selinux_opt,
8054023
@@ -8194,7 +8185,6 @@
8054023
 static swig_cast_info _swigc__p_int[] = {  {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
8054023
 static swig_cast_info _swigc__p_p_char[] = {  {&_swigt__p_p_char, 0, 0, 0},{0, 0, 0, 0}};
8054023
 static swig_cast_info _swigc__p_p_p_char[] = {  {&_swigt__p_p_p_char, 0, 0, 0},{0, 0, 0, 0}};
8054023
-static swig_cast_info _swigc__p_pid_t[] = {  {&_swigt__p_pid_t, 0, 0, 0},{0, 0, 0, 0}};
8054023
 static swig_cast_info _swigc__p_security_class_mapping[] = {  {&_swigt__p_security_class_mapping, 0, 0, 0},{0, 0, 0, 0}};
8054023
 static swig_cast_info _swigc__p_selinux_callback[] = {  {&_swigt__p_selinux_callback, 0, 0, 0},{0, 0, 0, 0}};
8054023
 static swig_cast_info _swigc__p_selinux_opt[] = {  {&_swigt__p_selinux_opt, 0, 0, 0},{0, 0, 0, 0}};
8054023
@@ -8212,7 +8202,6 @@
8054023
   _swigc__p_int,
8054023
   _swigc__p_p_char,
8054023
   _swigc__p_p_p_char,
8054023
-  _swigc__p_pid_t,
8054023
   _swigc__p_security_class_mapping,
8054023
   _swigc__p_selinux_callback,
8054023
   _swigc__p_selinux_opt,
e1e36a0
diff --exclude-from=exclude -N -u -r nsalibselinux/utils/matchpathcon.c libselinux-2.0.46/utils/matchpathcon.c
0fa749d
--- nsalibselinux/utils/matchpathcon.c	2007-07-16 14:20:45.000000000 -0400
e1e36a0
+++ libselinux-2.0.46/utils/matchpathcon.c	2008-01-03 15:23:32.000000000 -0500
0fa749d
@@ -17,10 +17,24 @@
0fa749d
 	exit(1);
0fa749d
 }
0fa749d
 
0fa749d
+static void
0fa749d
+#ifdef __GNUC__
0fa749d
+    __attribute__ ((format(printf, 1, 2)))
0fa749d
+#endif
0fa749d
+    myprintf(const char *fmt, ...)
0fa749d
+{
0fa749d
+	va_list ap;
0fa749d
+	va_start(ap, fmt);
0fa749d
+	vfprintf(stderr, fmt, ap);
0fa749d
+	va_end(ap);
0fa749d
+}
0fa749d
+
0fa749d
 int printmatchpathcon(char *path, int header, int mode)
0fa749d
 {
0fa749d
 	char *buf;
0fa749d
-	int rc = matchpathcon(path, mode, &buf;;
0fa749d
+	int rc;
0fa749d
+	set_matchpathcon_printf(myprintf);
0fa749d
+	rc = matchpathcon(path, mode, &buf;;
0fa749d
 	if (rc < 0) {
0fa749d
 		fprintf(stderr, "matchpathcon(%s) failed: %s\n", path,
0fa749d
 			strerror(errno));