comparison src/event/modules/ngx_poll_module.c @ 7442:e0e636ab10be

Events: fixed copying of old events in poll init. Previously, the code incorrectly assumed "ngx_event_t *" elements instead of "struct pollfd". This is mostly cosmetic change, as this code is never called now.
author Maxim Dounin <mdounin@mdounin.ru>
date Thu, 24 Jan 2019 21:50:37 +0300
parents a72886067bbb
children efd71d49bde0
comparison
equal deleted inserted replaced
7441:8acaa1161783 7442:e0e636ab10be
82 if (list == NULL) { 82 if (list == NULL) {
83 return NGX_ERROR; 83 return NGX_ERROR;
84 } 84 }
85 85
86 if (event_list) { 86 if (event_list) {
87 ngx_memcpy(list, event_list, sizeof(ngx_event_t *) * nevents); 87 ngx_memcpy(list, event_list, sizeof(struct pollfd) * nevents);
88 ngx_free(event_list); 88 ngx_free(event_list);
89 } 89 }
90 90
91 event_list = list; 91 event_list = list;
92 } 92 }