-
-
Notifications
You must be signed in to change notification settings - Fork 901
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Segmentation fault during XSLT transformation #1802
Comments
Thanks for reporting this. I'll take a look as soon as I have some free time. |
Thanks @flavorjones. In the meantime I've been able to narrow it down to the presence of |
Ah, that's great information. libxml2 does not support XPath 2.0 queries.
It's curious to me that it's _crashing_, though, and I will see if there's
anything we can do in Nokogiri to prevent that.
…On Thu, Oct 11, 2018 at 4:52 AM Oliver Jundt ***@***.***> wrote:
Thanks @flavorjones <https://github.com/flavorjones>. In the meantime
I've been able to narrow it down to the presence of xs:decimal calls in
the XSL which are XPath 2.0 features. If I remove those, Nokogiri no longer
crashes.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1802 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAAgD1qtZBGQnN_R7nWu4IaOtDKtEUh1ks5ujwbRgaJpZM4XU3zG>
.
|
@ojundt Are you able to provide a smaller repro script? If not maybe it's no biggie, but the test I have based on this data is large as a result. |
otherwise trivial XML errors will silently result in NULL being returned by xsltApplyStylesheet() and a subsequent segfault WIP NOTE that we need a test here to prevent regressions. The test I have available is too large to commit to the repo. Fixes #1802
just pushed branch |
@ojundt Never mind - I've got it shortened down to a very small size now. Thanks again for the repro! |
otherwise trivial XML errors will silently result in NULL being returned by xsltApplyStylesheet() and a subsequent segfault Fixes #1802
See PR #1860 to address this issue. |
…lt-in-transform [#1802] ensure we trap XML errors while applying XSLT stylesheet
What problems are you experiencing?
Nokogiri crashes with a segmentation fault during a XSLT transformation.
What's the output from
nokogiri -v
?Can you provide a self-contained script that reproduces what you're seeing?
Yes, see example.zip for a simple ruby script and example XSL and XML file.
The text was updated successfully, but these errors were encountered: