mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-08 10:31:50 -05:00
refactor: move DUMP_BANS_INTERVAL to banman.h
This commit is contained in:
parent
fadafb83cf
commit
fa36f3a295
2 changed files with 6 additions and 7 deletions
|
@ -5,16 +5,19 @@
|
||||||
#ifndef BITCOIN_BANMAN_H
|
#ifndef BITCOIN_BANMAN_H
|
||||||
#define BITCOIN_BANMAN_H
|
#define BITCOIN_BANMAN_H
|
||||||
|
|
||||||
#include <cstdint>
|
|
||||||
#include <memory>
|
|
||||||
|
|
||||||
#include <addrdb.h>
|
#include <addrdb.h>
|
||||||
#include <fs.h>
|
#include <fs.h>
|
||||||
#include <net_types.h> // For banmap_t
|
#include <net_types.h> // For banmap_t
|
||||||
#include <sync.h>
|
#include <sync.h>
|
||||||
|
|
||||||
|
#include <chrono>
|
||||||
|
#include <cstdint>
|
||||||
|
#include <memory>
|
||||||
|
|
||||||
// NOTE: When adjusting this, update rpcnet:setban's help ("24h")
|
// NOTE: When adjusting this, update rpcnet:setban's help ("24h")
|
||||||
static constexpr unsigned int DEFAULT_MISBEHAVING_BANTIME = 60 * 60 * 24; // Default 24-hour ban
|
static constexpr unsigned int DEFAULT_MISBEHAVING_BANTIME = 60 * 60 * 24; // Default 24-hour ban
|
||||||
|
// How often to dump addresses to banlist.dat
|
||||||
|
static constexpr std::chrono::minutes DUMP_BANS_INTERVAL{15};
|
||||||
|
|
||||||
class CClientUIInterface;
|
class CClientUIInterface;
|
||||||
class CNetAddr;
|
class CNetAddr;
|
||||||
|
|
|
@ -86,10 +86,6 @@ static const bool DEFAULT_PROXYRANDOMIZE = true;
|
||||||
static const bool DEFAULT_REST_ENABLE = false;
|
static const bool DEFAULT_REST_ENABLE = false;
|
||||||
static const bool DEFAULT_STOPAFTERBLOCKIMPORT = false;
|
static const bool DEFAULT_STOPAFTERBLOCKIMPORT = false;
|
||||||
|
|
||||||
// How often to dump addresses to banlist.dat
|
|
||||||
static constexpr std::chrono::minutes DUMP_BANS_INTERVAL{15};
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef WIN32
|
#ifdef WIN32
|
||||||
// Win32 LevelDB doesn't use filedescriptors, and the ones used for
|
// Win32 LevelDB doesn't use filedescriptors, and the ones used for
|
||||||
// accessing block files don't count towards the fd_set size limit
|
// accessing block files don't count towards the fd_set size limit
|
||||||
|
|
Loading…
Add table
Reference in a new issue