(bind-func sys_file_open (lambda (filename flags permissions pool) (letz ((file:apr_file_t** (zalloc)) (res (apr_file_open file (cstring filename) flags permissions pool))) (if (= res APR_SUCCESS) (pref file 0) null))))