Bug 188106 - matchpathcon not usable from Python
Summary: matchpathcon not usable from Python
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: libselinux
Version: 5
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Daniel Walsh
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2006-04-06 02:42 UTC by Miloslav Trmač
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2006-04-11 18:26:47 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Typedef mode_t as unsigned (390 bytes, patch)
2006-04-06 02:42 UTC, Miloslav Trmač
no flags Details | Diff

Description Miloslav Trmač 2006-04-06 02:42:58 UTC
$ python
Python 2.4.2 (#1, Feb 12 2006, 03:59:46)
[GCC 4.1.0 20060210 (Red Hat 4.1.0-0.24)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import selinux
>>> selinux.matchpathcon('/', 0)
Traceback (most recent call last):
  File "<stdin>", line 1, in ?
TypeError: argument number 2: a 'mode_t *' is expected, 'int(0)' is received


Version-Release number of selected component (if applicable):
libselinux-python-1.30-1.fc5

My knowledge of swig is minimal, but the attached patch seems to fix it.

Comment 1 Miloslav Trmač 2006-04-06 02:42:58 UTC
Created attachment 127386 [details]
Typedef mode_t as unsigned

Comment 2 Daniel Walsh 2006-04-11 18:26:47 UTC
Fixed in rawhide - libselinux-1.30.1-1

Is this something worth backporting to FC5, or should I just wait until
something more important comes up?


Comment 3 Miloslav Trmač 2006-04-11 20:43:15 UTC
Thanks!

I don't need it urgently, but as my main workstation has FC5 installed, it would
be nice to get a fix in FC5 sometime.


Note You need to log in before you can comment on or make changes to this bug.