Might as well ask another question of the list.

I've written a ctypes-based Python wrapper around the 'readdir'
function. (I want access to the dt_type field of the result, without
calling stat().)

However, it feels very... fragile. What happens on a different *nix
which uses a different size of integers? Is Linux even consistent
between 32 and 64 bits? (That's a rhetorical question.) What happens on
a different *nix with the fields in a different order, or without a
dt_type field?

It somehow feels wrong that you get way less help with this than you
would get even from C. Is that just how it is with ctypes? Or is there
some way around it? I'm sort of tempted to write a C module whose sole
purpose is to wrap readdir...

Evan


Attachment: signature.asc
Description: OpenPGP digital signature

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to