zorba-coders team mailing list archive
-
zorba-coders team
-
Mailing list archive
-
Message #11129
[Bug 1015560] [NEW] segmentation fault when using fetch and parse in one flwor
Public bug reported:
Zorba destroys input stream produced by fetch:content too early if
optimization is on.
example query:
import module namespace fetch = "http://www.zorba-xquery.com/modules/fetch";;
import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";;
import schema namespace opt = "http://www.zorba-xquery.com/modules/xml-options";;
let $xmlcontent := fetch:content("file.xml")
let $contents := parse-xml:parse(
$xmlcontent,
<opt:options>
<opt:parse-external-parsed-entity />
</opt:options>)
return $contents
file:xml:
any random xml file
executions:
$ ~/zorba/build/bin/zorba -q test.xq -f --optimization-level O0
<?xml version="1.0" encoding="UTF-8"?>
<a/>
$ ~/zorba/build/bin/zorba -q test.xq -f --optimization-level O1
<?xml version="1.0" encoding="UTF-8"?>
Segmentation fault (core dumped)
** Affects: zorba
Importance: Undecided
Assignee: Matthias Brantner (matthias-brantner)
Status: New
--
You received this bug notification because you are a member of Zorba
Coders, which is the registrant for Zorba.
https://bugs.launchpad.net/bugs/1015560
Title:
segmentation fault when using fetch and parse in one flwor
Status in Zorba - The XQuery Processor:
New
Bug description:
Zorba destroys input stream produced by fetch:content too early if
optimization is on.
example query:
import module namespace fetch = "http://www.zorba-xquery.com/modules/fetch";;
import module namespace parse-xml = "http://www.zorba-xquery.com/modules/xml";;
import schema namespace opt = "http://www.zorba-xquery.com/modules/xml-options";;
let $xmlcontent := fetch:content("file.xml")
let $contents := parse-xml:parse(
$xmlcontent,
<opt:options>
<opt:parse-external-parsed-entity />
</opt:options>)
return $contents
file:xml:
any random xml file
executions:
$ ~/zorba/build/bin/zorba -q test.xq -f --optimization-level O0
<?xml version="1.0" encoding="UTF-8"?>
<a/>
$ ~/zorba/build/bin/zorba -q test.xq -f --optimization-level O1
<?xml version="1.0" encoding="UTF-8"?>
Segmentation fault (core dumped)
To manage notifications about this bug go to:
https://bugs.launchpad.net/zorba/+bug/1015560/+subscriptions
Follow ups
References