Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
The Tor Project
Network Health
Metrics
Library
Commits
0917016f
Commit
0917016f
authored
Jun 16, 2017
by
Karsten Loesing
Browse files
Fix a regression in parsing descriptors.
parent
1ac25469
Changes
2
Hide whitespace changes
Inline
Side-by-side
CHANGELOG.md
View file @
0917016f
# Changes in version 1.9.0 - 2017-06-??
# Changes in version 1.8.2 - 2017-06-16
*
Medium changes
-
Fix a regression where any DescriptorParseException thrown while
parsing a descriptor is encapsulated and rethrown as
RuntimeException.
# Changes in version 1.8.1 - 2017-06-08
...
...
src/main/java/org/torproject/descriptor/impl/DescriptorParserImpl.java
View file @
0917016f
...
...
@@ -195,9 +195,15 @@ public class DescriptorParserImpl implements DescriptorParser {
try
{
return
constructor
.
newInstance
(
rawDescriptorBytes
,
offsetAndLength
,
failUnrecognizedDescriptorLines
);
}
catch
(
InstantiationException
|
IllegalAccessException
|
InvocationTargetException
e
)
{
throw
new
RuntimeException
();
}
catch
(
InvocationTargetException
e
)
{
if
(
null
!=
e
.
getCause
()
&&
e
.
getCause
()
instanceof
DescriptorParseException
)
{
throw
(
DescriptorParseException
)
e
.
getCause
();
}
else
{
throw
new
RuntimeException
(
e
);
}
}
catch
(
InstantiationException
|
IllegalAccessException
e
)
{
throw
new
RuntimeException
(
e
);
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment