|
Pharos 0.7.23
Modern Web Framework & Web App Hosting Service.
|
Declares native static artifact serving helpers. More...
Go to the source code of this file.
Functions | |
Native static serving helpers | |
| int | native_serve_static_file (NativeConnection *connection, const char *root, const char *path, const HttpRequest *request, const char *log_path) |
| Serves one static artifact response from a root directory. | |
Declares native static artifact serving helpers.
Definition in file native_static_serve.h.
| int native_serve_static_file | ( | NativeConnection * | connection, |
| const char * | root, | ||
| const char * | path, | ||
| const HttpRequest * | request, | ||
| const char * | log_path ) |
Serves one static artifact response from a root directory.
| connection | Connection receiving the response. |
| root | Artifact root directory. |
| path | Request target path. |
| request | Parsed request metadata. |
| log_path | Log path used for access and error logging. |
Definition at line 24 of file native_static_serve.c.
References dup_range(), http_status_text_native(), HttpRequest::method, mime_type_for_path(), native_connection_printf(), native_connection_write(), native_dispatch_response_file_for_request(), native_send_text_response(), native_static_serve_strdup, native_write_access_log(), native_write_error_log(), path_exists(), path_is_directory(), path_join(), and starts_with().
Referenced by handle_app_or_runtime_request(), and serve_static_root().