Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Container Registry
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
The Tor Project
Core
Tor
Commits
1b026efc
Commit
1b026efc
authored
12 years ago
by
Nick Mathewson
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'origin/maint-0.2.4'
parents
3dfd1ebf
ee3cc44f
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
changes/bug7302
+11
-0
11 additions, 0 deletions
changes/bug7302
src/or/control.c
+3
-0
3 additions, 0 deletions
src/or/control.c
src/or/status.c
+7
-4
7 additions, 4 deletions
src/or/status.c
with
21 additions
and
4 deletions
changes/bug7302
0 → 100644
+
11
−
0
View file @
1b026efc
o Minor bugfixes:
- Don't log inappropriate heartbeat messages when hibernating: a
hibernating node is _expected_ to drop out of the consensus,
decide it isn't bootstrapped, and so forth. Fixes part of bug
7302; bugfix on 0.2.3.1-alpha.
- Don't complain about bootstrapping problems while hibernating.
These complaints reflect a general code problems, but not one
with any problematic effects. (No connections are actually
opened.) Fixes part of bug 7302; bugfix on 0.2.3.2-alpha.
This diff is collapsed.
Click to expand it.
src/or/control.c
+
3
−
0
View file @
1b026efc
...
...
@@ -4715,6 +4715,9 @@ control_event_bootstrap_problem(const char *warn, int reason)
!
any_pending_bridge_descriptor_fetches
())
recommendation
=
"warn"
;
if
(
we_are_hibernating
())
recommendation
=
"ignore"
;
while
(
status
>=
0
&&
bootstrap_status_to_string
(
status
,
&
tag
,
&
summary
)
<
0
)
status
--
;
/* find a recognized status string based on current progress */
status
=
bootstrap_percent
;
/* set status back to the actual number */
...
...
This diff is collapsed.
Click to expand it.
src/or/status.c
+
7
−
4
View file @
1b026efc
...
...
@@ -14,6 +14,7 @@
#include
"router.h"
#include
"circuitlist.h"
#include
"main.h"
#include
"hibernate.h"
/** Return the total number of circuits. */
static
int
...
...
@@ -86,11 +87,12 @@ log_heartbeat(time_t now)
char
*
uptime
=
NULL
;
const
routerinfo_t
*
me
;
double
r
=
tls_get_write_overhead_ratio
();
const
int
hibernating
=
we_are_hibernating
();
const
or_options_t
*
options
=
get_options
();
(
void
)
now
;
if
(
public_server_mode
(
options
))
{
if
(
public_server_mode
(
options
)
&&
!
hibernating
)
{
/* Let's check if we are in the current cached consensus. */
if
(
!
(
me
=
router_get_my_routerinfo
()))
return
-
1
;
/* Something stinks, we won't even attempt this. */
...
...
@@ -105,10 +107,11 @@ log_heartbeat(time_t now)
bw_sent
=
bytes_to_usage
(
get_bytes_written
());
log_fn
(
LOG_NOTICE
,
LD_HEARTBEAT
,
"Heartbeat: Tor's uptime is %s, with %d "
"circuits open. I've sent %s and received %s."
,
uptime
,
count_circuits
(),
bw_sent
,
bw_rcvd
);
"circuits open. I've sent %s and received %s.%s"
,
uptime
,
count_circuits
(),
bw_sent
,
bw_rcvd
,
hibernating
?
" We are currently hibernating."
:
""
);
if
(
stats_n_data_cells_packaged
)
if
(
stats_n_data_cells_packaged
&&
!
hibernating
)
log_notice
(
LD_HEARTBEAT
,
"Average packaged cell fullness: %2.3f%%"
,
100
*
(
U64_TO_DBL
(
stats_n_data_bytes_packaged
)
/
U64_TO_DBL
(
stats_n_data_cells_packaged
*
RELAY_PAYLOAD_SIZE
))
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment