| 1006 | } |
| 1007 | |
| 1008 | void h2_response_clean(void) |
| 1009 | { |
| 1010 | int i; |
| 1011 | |
| 1012 | if (ng_h2_response->hdrs) { |
| 1013 | for (i = 0; i < ng_h2_response->hdrs_len; i++) { |
| 1014 | shm_free(ng_h2_response->hdrs[i].name); |
| 1015 | shm_free(ng_h2_response->hdrs[i].value); |
| 1016 | } |
| 1017 | |
| 1018 | shm_free(ng_h2_response->hdrs); |
| 1019 | ng_h2_response->hdrs = NULL; |
| 1020 | ng_h2_response->hdrs_len = 0; |
| 1021 | } |
| 1022 | |
| 1023 | if (ng_h2_response->body.s) { |
| 1024 | shm_free(ng_h2_response->body.s); |
| 1025 | memset(&ng_h2_response->body, 0, sizeof ng_h2_response->body); |
| 1026 | } |
| 1027 | |
| 1028 | ng_h2_response->code = 0; |
| 1029 | } |
| 1030 | |
| 1031 | void http2_server(int rank) |
| 1032 | { |
no test coverage detected