mirror of
https://github.com/libevent/libevent.git
synced 2025-01-31 09:12:55 +08:00
Merge #1152 -- remove no op evdns functions
* upstream/pr/1152: dns: remove evdns_set_transaction_id_fn dns: remove evdns_set_random_bytes_fn
This commit is contained in:
commit
8e03f49597
11
evdns.c
11
evdns.c
@ -1595,17 +1595,6 @@ err:
|
||||
#undef GET8
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
evdns_set_transaction_id_fn(ev_uint16_t (*fn)(void))
|
||||
{
|
||||
}
|
||||
|
||||
void
|
||||
evdns_set_random_bytes_fn(void (*fn)(char *, size_t))
|
||||
{
|
||||
}
|
||||
|
||||
/* Try to choose a strong transaction id which isn't already in flight */
|
||||
static u16
|
||||
transaction_id_pick(struct evdns_base *base) {
|
||||
|
@ -602,31 +602,6 @@ typedef void (*evdns_debug_log_fn_type)(int is_warning, const char *msg);
|
||||
EVENT2_EXPORT_SYMBOL
|
||||
void evdns_set_log_fn(evdns_debug_log_fn_type fn);
|
||||
|
||||
/**
|
||||
Set a callback that will be invoked to generate transaction IDs. By
|
||||
default, we pick transaction IDs based on the current clock time, which
|
||||
is bad for security.
|
||||
|
||||
@param fn the new callback, or NULL to use the default.
|
||||
|
||||
NOTE: This function has no effect in Libevent 2.0.4-alpha and later,
|
||||
since Libevent now provides its own secure RNG.
|
||||
*/
|
||||
EVENT2_EXPORT_SYMBOL
|
||||
void evdns_set_transaction_id_fn(ev_uint16_t (*fn)(void));
|
||||
|
||||
/**
|
||||
Set a callback used to generate random bytes. By default, we use
|
||||
the same function as passed to evdns_set_transaction_id_fn to generate
|
||||
bytes two at a time. If a function is provided here, it's also used
|
||||
to generate transaction IDs.
|
||||
|
||||
NOTE: This function has no effect in Libevent 2.0.4-alpha and later,
|
||||
since Libevent now provides its own secure RNG.
|
||||
*/
|
||||
EVENT2_EXPORT_SYMBOL
|
||||
void evdns_set_random_bytes_fn(void (*fn)(char *, size_t));
|
||||
|
||||
/*
|
||||
* Functions used to implement a DNS server.
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user