Apache HTTPD
Classes | Macros | Typedefs | Functions | Variables
mod_dialup.c File Reference
#include "httpd.h"
#include "http_core.h"
#include "util_filter.h"
#include "http_log.h"
#include "http_config.h"
#include "http_request.h"
#include "http_protocol.h"
#include "ap_mpm.h"

Go to the source code of this file.

Classes

struct  dialup_dcfg_t
 
struct  dialup_baton_t
 
struct  modem_speed_t
 

Macros

#define APR_HOOK_ALMOST_LAST   (APR_HOOK_REALLY_LAST - 1)
 
#define BITRATE_TO_BYTES(x)   ((1000 * x)/8)
 

Typedefs

typedef struct dialup_dcfg_t dialup_dcfg_t
 
typedef struct dialup_baton_t dialup_baton_t
 
typedef struct modem_speed_t modem_speed_t
 

Functions

static int dialup_send_pulse (dialup_baton_t *db)
 
static void dialup_callback (void *baton)
 
static int dialup_handler (request_rec *r)
 
static void dialup_register_hooks (apr_pool_t *p)
 
static const charcmd_modem_standard (cmd_parms *cmd, void *dconf, const char *input)
 
static void * dialup_dcfg_create (apr_pool_t *p, char *dummy)
 

Variables

static const modem_speed_t modem_bitrates []
 
static const command_rec dialup_cmds []
 
static int *const aplog_module_index = &( dialup_module.module_index)
 

Macro Definition Documentation

◆ APR_HOOK_ALMOST_LAST

#define APR_HOOK_ALMOST_LAST   (APR_HOOK_REALLY_LAST - 1)

Definition at line 222 of file mod_dialup.c.

◆ BITRATE_TO_BYTES

#define BITRATE_TO_BYTES (   x)    ((1000 * x)/8)

Definition at line 237 of file mod_dialup.c.

Typedef Documentation

◆ dialup_baton_t

◆ dialup_dcfg_t

◆ modem_speed_t

Function Documentation

◆ cmd_modem_standard()

static const char * cmd_modem_standard ( cmd_parms cmd,
void *  dconf,
const char input 
)
static

Definition at line 252 of file mod_dialup.c.

◆ dialup_callback()

static void dialup_callback ( void *  baton)
static

< Module will handle the remainder of the request. * The core will never invoke the request again,

< Module has served the response completely * - it's safe to die() with no more output

Definition at line 104 of file mod_dialup.c.

◆ dialup_dcfg_create()

static void * dialup_dcfg_create ( apr_pool_t p,
char dummy 
)
static

Definition at line 279 of file mod_dialup.c.

◆ dialup_handler()

static int dialup_handler ( request_rec r)
static

RFC 2616: HTTP

< Module declines to handle

< Module declines to handle

< Open the file for reading

<

Deprecated:
See also
APR_FOPEN_READ

< Open the file in binary mode (This flag is ignored on UNIX because it has no meaning)

<

Deprecated:
See also
APR_FOPEN_BINARY

< Module declines to handle

< Module has handled this stage.

< Module declines to handle

< Module will handle the remainder of the request. * The core will never invoke the request again,

< Module has served the response completely * - it's safe to die() with no more output

< Module will handle the remainder of the request. * The core will never invoke the request again,

Definition at line 133 of file mod_dialup.c.

◆ dialup_register_hooks()

static void dialup_register_hooks ( apr_pool_t p)
static

Definition at line 226 of file mod_dialup.c.

◆ dialup_send_pulse()

static int dialup_send_pulse ( dialup_baton_t db)
static

< Module has served the response completely * - it's safe to die() with no more output

< Module will handle the remainder of the request. * The core will never invoke the request again,

Definition at line 47 of file mod_dialup.c.

Variable Documentation

◆ aplog_module_index

int* const aplog_module_index = &( dialup_module.module_index)
static

Definition at line 297 of file mod_dialup.c.

◆ dialup_cmds

const command_rec dialup_cmds[]
static
Initial value:
=
{
{ "ModemStandard" , cmd_modem_standard , NULL , 64 , TAKE1, "Modem Standard to.. simulate. " "Must be one of: 'V.21', 'V.26bis', 'V.32', 'V.34', or 'V.92'" },
{NULL}
}
@ TAKE1
Definition http_config.h:51
static const char * cmd_modem_standard(cmd_parms *cmd, void *dconf, const char *input)
Definition mod_dialup.c:252
return NULL
Definition mod_so.c:359

Definition at line 289 of file mod_dialup.c.

◆ modem_bitrates

const modem_speed_t modem_bitrates[]
static
Initial value:
=
{
{"V.21", ((1000 * 0.1 )/8)},
{"V.26bis", ((1000 * 2.4 )/8)},
{"V.32", ((1000 * 9.6 )/8)},
{"V.34", ((1000 * 28.8 )/8)},
{"V.92", ((1000 * 56.0 )/8)},
{"i-was-rich-and-got-a-leased-line", ((1000 * 1500 )/8)},
{NULL, 0}
}

Definition at line 240 of file mod_dialup.c.