MCPcopy Create free account
hub / github.com/apache/httpd / dialup_callback

Function dialup_callback

modules/test/mod_dialup.c:103–130  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

101}
102
103static void
104dialup_callback(void *baton)
105{
106 int status;
107 dialup_baton_t *db = (dialup_baton_t *)baton;
108
109 apr_thread_mutex_lock(db->r->invoke_mtx);
110
111 status = dialup_send_pulse(db);
112
113 if (status == SUSPENDED) {
114 ap_mpm_register_timed_callback(apr_time_from_sec(1), dialup_callback, baton);
115 }
116 else if (status == DONE) {
117 apr_thread_mutex_unlock(db->r->invoke_mtx);
118 ap_finalize_request_protocol(db->r);
119 ap_process_request_after_handler(db->r);
120 return;
121 }
122 else {
123 ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, db->r, APLOGNO(01868)
124 "dialup: pulse returned: %d", status);
125 db->r->status = HTTP_OK;
126 ap_die(status, db->r);
127 }
128
129 apr_thread_mutex_unlock(db->r->invoke_mtx);
130}
131
132static int
133dialup_handler(request_rec *r)

Callers

nothing calls this directly

Calls 5

dialup_send_pulseFunction · 0.85
ap_dieFunction · 0.85

Tested by

no test coverage detected