Don't silently log and continue when changing tor's config fails
We only throw an error when the setconf
fails. We should not do that, especially when configuring a bridge.
let errorObject = {};
if (!this._tlps.TorSetConfWithReply(settingsObject, errorObject)) {
throw new Error(errorObject.details);
}
An an example, when using provide a bridge
with foo bar baz
we get the following log messages:
Jul 16 15:55:57.000 [warn] Error parsing Bridge address 'bar'
Jul 16 15:55:57.000 [warn] Controller gave us config lines that didn't validate: Bridge line did not parse. See logs for details.
JavaScript error: resource:///modules/TorProtocolService.jsm, line 128: Error: Unacceptable option value: Bridge line did not parse. See logs for details.
But the user has zero notification about this failure.
Edited by Roger Dingledine