mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 05:33:47 +01:00
ok, i'm not so good at counting
svn:r10117
This commit is contained in:
parent
0ce53ca817
commit
10efbed2f5
@ -189,7 +189,7 @@ static config_var_t _option_vars[] = {
|
|||||||
VAR("LongLivedPorts", CSV, LongLivedPorts,
|
VAR("LongLivedPorts", CSV, LongLivedPorts,
|
||||||
"21,22,706,1863,5050,5190,5222,5223,6667,6697,8300"),
|
"21,22,706,1863,5050,5190,5222,5223,6667,6697,8300"),
|
||||||
VAR("MapAddress", LINELIST, AddressMap, NULL),
|
VAR("MapAddress", LINELIST, AddressMap, NULL),
|
||||||
VAR("MaxAdvertisedBandwidth",MEMUNIT,MaxAdvertisedBandwidth,"2 GB"),
|
VAR("MaxAdvertisedBandwidth",MEMUNIT,MaxAdvertisedBandwidth,"1 GB"),
|
||||||
VAR("MaxCircuitDirtiness", INTERVAL, MaxCircuitDirtiness, "10 minutes"),
|
VAR("MaxCircuitDirtiness", INTERVAL, MaxCircuitDirtiness, "10 minutes"),
|
||||||
VAR("MaxOnionsPending", UINT, MaxOnionsPending, "100"),
|
VAR("MaxOnionsPending", UINT, MaxOnionsPending, "100"),
|
||||||
OBSOLETE("MonthlyAccountingStart"),
|
OBSOLETE("MonthlyAccountingStart"),
|
||||||
@ -2285,8 +2285,8 @@ ensure_bandwidth_cap(uint64_t value, const char *desc, char **msg)
|
|||||||
int r;
|
int r;
|
||||||
char buf[1024];
|
char buf[1024];
|
||||||
if (value > ROUTER_MAX_DECLARED_BANDWIDTH) {
|
if (value > ROUTER_MAX_DECLARED_BANDWIDTH) {
|
||||||
r = tor_snprintf(buf, sizeof(buf), "%s must be at most %d",
|
r = tor_snprintf(buf, sizeof(buf), "%s ("U64_FORMAT") must be at most %d",
|
||||||
desc, ROUTER_MAX_DECLARED_BANDWIDTH);
|
desc, value, ROUTER_MAX_DECLARED_BANDWIDTH);
|
||||||
*msg = tor_strdup(r >= 0 ? buf : "internal error");
|
*msg = tor_strdup(r >= 0 ? buf : "internal error");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user