diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinuxswig.i libselinux-2.0.64/src/selinuxswig.i --- nsalibselinux/src/selinuxswig.i 2008-05-06 14:33:15.000000000 -0400 +++ libselinux-2.0.64/src/selinuxswig.i 2008-05-07 13:08:06.000000000 -0400 @@ -5,6 +5,7 @@ %module selinux %{ #include "selinux/selinux.h" + #include "../include/selinux/avc.h" #include "../include/selinux/selinux.h" #include "../include/selinux/get_default_type.h" #include "../include/selinux/get_context_list.h" @@ -47,6 +48,10 @@ %ignore set_matchpathcon_invalidcon; %ignore set_matchpathcon_canoncon; +%ignore avc_add_callback; + %include "../include/selinux/selinux.h" +%include "../include/selinux/avc.h" %include "../include/selinux/get_default_type.h" %include "../include/selinux/get_context_list.h" + diff --exclude-from=exclude -N -u -r nsalibselinux/src/selinuxswig_python.i libselinux-2.0.64/src/selinuxswig_python.i --- nsalibselinux/src/selinuxswig_python.i 2007-10-01 09:54:35.000000000 -0400 +++ libselinux-2.0.64/src/selinuxswig_python.i 2008-05-07 13:08:06.000000000 -0400 @@ -16,6 +16,20 @@ $result = SWIG_Python_AppendOutput($result, list); } +/* return a sid along with the result */ +%typemap(argout) (security_id_t * sid) { + if (*$1) { + %append_output(SWIG_NewPointerObj(*$1, $descriptor(security_id_t), 0)); + } else { + Py_INCREF(Py_None); + %append_output(Py_None); + } +} + +%typemap(in,numinputs=0) security_id_t *(security_id_t temp) { + $1 = &temp; +} + /* Makes security_compute_user() return a Python list of contexts */ %typemap(argout) (security_context_t **con) { PyObject* plist;
Attachment:
libselinux-rhat.patch.sig
Description: PGP signature