forked from nginx/ngx-rust
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmod.rs
66 lines (62 loc) · 1.77 KB
/
mod.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
mod buffer;
mod pool;
mod status;
mod string;
pub use buffer::*;
pub use pool::*;
pub use status::*;
pub use string::*;
/// Static empty configuration directive initializer for [`ngx_command_t`].
///
/// This is typically used to terminate an array of configuration directives.
///
/// [`ngx_command_t`]: https://nginx.org/en/docs/dev/development_guide.html#config_directives
#[macro_export]
macro_rules! ngx_null_command {
() => {
ngx_command_t {
name: $crate::ngx_null_string!(),
type_: 0,
set: None,
conf: 0,
offset: 0,
post: ::std::ptr::null_mut(),
}
};
}
/// Static empty configuration variable initializer for [`ngx_http_variable_t`].
///
/// This is typically used to terminate an array of HTTP variable types.
///
/// [`ngx_http_variable_t`]: https://nginx.org/en/docs/dev/development_guide.html#http_variables
#[macro_export]
macro_rules! ngx_http_null_variable {
() => {
ngx_http_variable_t {
name: $crate::ngx_null_string!(),
set_handler: None,
get_handler: None,
data: 0,
flags: 0,
index: 0,
}
};
}
/// Static empty configuration variable initializer for [`ngx_stream_variable_t`].
///
/// This is typically used to terminate an array of Stream variable types.
///
/// [`ngx_stream_variable_t`]: https://github.com/nginx/nginx/blob/1a8ef991d92d22eb8aded7f49595dd31a639e8a4/src/stream/ngx_stream_variables.h#L21
#[macro_export]
macro_rules! ngx_stream_null_variable {
() => {
ngx_stream_variable_t {
name: $crate::ngx_null_string!(),
set_handler: None,
get_handler: None,
data: 0,
flags: 0,
index: 0,
}
};
}