NetSurf
Functions
filetype.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void monkey_fetch_filetype_init (const char *mimefile)
 
void monkey_fetch_filetype_fin (void)
 
const char * monkey_fetch_filetype (const char *unix_path)
 Determine the MIME type of a local file. More...
 

Function Documentation

◆ monkey_fetch_filetype()

const char * monkey_fetch_filetype ( const char *  unix_path)

Determine the MIME type of a local file.

Note
used in file fetcher
Parameters
unix_pathUnix style path to file on disk
Returns
Pointer to static MIME type string (should not be freed) not NULL. invalidated on next call to fetch_filetype.

Definition at line 182 of file filetype.c.

References ascii_to_lower(), hash_get(), mime_hash, and type.

Here is the call graph for this function:

◆ monkey_fetch_filetype_fin()

void monkey_fetch_filetype_fin ( void  )

Definition at line 168 of file filetype.c.

References hash_destroy(), and mime_hash.

Referenced by monkey_quit().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ monkey_fetch_filetype_init()

void monkey_fetch_filetype_init ( const char *  mimefile)

Definition at line 54 of file filetype.c.

References ascii_is_space(), hash_add(), hash_create(), HASH_SIZE, line(), MAX_LINE_LEN, mime_hash, NSLOG, and type.

Referenced by main().

Here is the call graph for this function:
Here is the caller graph for this function: