Make AutoPatcher stuff more compatible with C API