Opened 8 years ago

Closed 8 years ago

Last modified 7 years ago

#3743 closed defect (fixed)

Sending Tor a HUP signal gives a bunch of warnings

Reported by: Sebastian Owned by:
Priority: Medium Milestone: Tor: 0.2.3.x-final
Component: Core Tor/Tor Version:
Severity: Keywords: tor-client
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

In 5a801a8c8b71c9551a80913398135809cb10cecd we started implementing a change that sends CONF_CHANGED events when a tor configuration option changed. This has the unintended side-effect of generating a whole bunch of warnings for all CONFIG_TYPE_LINELIST_S options:

[warn] Can't return context-sensitive 'HiddenServiceDir' on its own
[warn] Can't return context-sensitive 'HiddenServiceDir' on its own
[warn] Can't return context-sensitive 'HiddenServicePort' on its own
... etc

Fixing option_is_same() might serve as a workaround, but it seems that the whole implementation doesn't have a way to deal with these config options correctly, so maybe even the spec needs to be re-thought here.

Child Tickets

Change History (8)

comment:1 Changed 8 years ago by Sebastian

Aha. The problem is that calling option_is_same() is illegal for LINELIST options, as its documentation specifies. This needs a broader workaround.

comment:2 in reply to:  1 Changed 8 years ago by krkhan

Replying to Sebastian:

Aha. The problem is that calling option_is_same() is illegal for LINELIST options, as its documentation specifies. This needs a broader workaround.

For the time being, this patch skips comparisons of LINELIST and OBSOLETE options.

comment:3 Changed 8 years ago by Sebastian

Status: newneeds_review

Right, this will fix the warning. But it will also mean that controllers don't hear about changes to those config options, which kind of means they don't get much use out of this feature iiuic

comment:4 Changed 8 years ago by nickm

Looking at the code, you only want to skip comparison of LINELIST_S. And it looks like your patch does that -- no idea why you're saying LINELIST here; that's something different.

Sebastian -- it's okay to omit comparison in LINELIST_S/OBSOLETE: The former is always part of a LINELIST_V; and the latter never takes a value.

comment:5 Changed 8 years ago by Sebastian

ohh, good. I missed that. Thanks for the explanation.

comment:6 Changed 8 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

Merged with a tweak: It's not necessary to call config_find_option() to get the config_var_t in that loop, since the variable you get is the same as options_format.vars[i].

comment:7 Changed 7 years ago by nickm

Keywords: tor-client added

comment:8 Changed 7 years ago by nickm

Component: Tor ClientTor
Note: See TracTickets for help on using tickets.