Source: Add cm_fileno wrapper

And use it where appropriate.
5 files changed