- Python Home
- About
- News
- Documentation
- Downloads
- Community
- Foundation
- Developer's Guide
- Issue Tracker
- Issues
- Summaries
- User
- Administration
- Help
Message64419
This issue tracker has been migrated to GitHub,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
| Author | loewis |
|---|---|
| Recipients | collinwinter, loewis, nnorwitz, theller |
| Date | 2008-03-24.16:41:37 |
| SpamBayes Score | 0.0039359336 |
| Marked as misclassified | No |
| Message-id | <1206376898.67.0.57487519334.issue2470@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
In the simplest case, convert
import dl
libc = dl.open("libc.so.6")
iconv = libc.call("iconv_open", "ISO-8859-1", "ISO-8859-2")
print(iconv)
to
import ctypes
libc = ctypes.CDLL("libc.so.6")
iconv = libc.iconv_open("ISO-8859-1", "ISO-8859-2")
print(iconv)
Notice that <dlobject>.call has up to 11 arguments, the first one being
the function name.
Thomas, is it the case that all calls to dl.call can be converted to a
ctypes call without parameter conversion? dl supports these parameter
types:
- byte string, passed as char*
- integers, passed as int
- None, passed as NULL |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2008-03-24 16:41:39 | loewis | set | spambayes_score: 0.00393593 -> 0.0039359336 recipients: + loewis, nnorwitz, theller, collinwinter |
| 2008-03-24 16:41:38 | loewis | set | spambayes_score: 0.00393593 -> 0.00393593 messageid: <1206376898.67.0.57487519334.issue2470@psf.upfronthosting.co.za> |
| 2008-03-24 16:41:37 | loewis | link | issue2470 messages |
| 2008-03-24 16:41:37 | loewis | create | |

