diff options
author | Nicholas Marriott <nicholas.marriott@gmail.com> | 2021-05-03 10:49:51 +0100 |
---|---|---|
committer | Nicholas Marriott <nicholas.marriott@gmail.com> | 2021-06-10 09:22:47 +0100 |
commit | aaf87abfb4a93067c3fcb78d604636886252791a (patch) | |
tree | 25ea26c88029dd22c92ea3a206d550f4a3608d5f /file.c | |
parent | bacb4d1b4df77c0f4ad940edcd75bbafef8efa9f (diff) | |
download | rtmux-aaf87abfb4a93067c3fcb78d604636886252791a.tar.gz rtmux-aaf87abfb4a93067c3fcb78d604636886252791a.tar.bz2 rtmux-aaf87abfb4a93067c3fcb78d604636886252791a.zip |
Fire check callback after cleaning up event so it does not get stuck, from
Jeongho Jang in GitHub issue 2695.
Diffstat (limited to 'file.c')
-rw-r--r-- | file.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -503,14 +503,14 @@ file_write_error_callback(__unused struct bufferevent *bev, __unused short what, log_debug("write error file %d", cf->stream); - if (cf->cb != NULL) - cf->cb(NULL, NULL, 0, -1, NULL, cf->data); - bufferevent_free(cf->event); cf->event = NULL; close(cf->fd); cf->fd = -1; + + if (cf->cb != NULL) + cf->cb(NULL, NULL, 0, -1, NULL, cf->data); } /* Client file write callback. */ |