Public bug reported:

The following query sometimes causes Zorba to crash:

import module namespace ddl = 
"http://www.zorba-xquery.com/modules/store/dynamic/collections/ddl";;
import module namespace dml = 
"http://www.zorba-xquery.com/modules/store/dynamic/collections/dml";;
import module namespace ref = 
"http://www.zorba-xquery.com/modules/node-reference";;

ddl:create(xs:QName("ddl:coll"));
dml:insert-nodes-last(xs:QName("ddl:coll"),element {"bb"}{text {"aa"}});
ref:node-reference(dml:collection(xs:QName("ddl:coll")))

This is caused by the following cast: 
const OrdPathNode* n = static_cast<const OrdPathNode*>(node); 
which is not correct when node is a TextNode

** Affects: zorba
     Importance: Medium
     Assignee: Federico Cavalieri (fcavalieri)
         Status: New

** Changed in: zorba
     Assignee: (unassigned) => Federico Cavalieri (fcavalieri)

** Changed in: zorba
   Importance: Undecided => Medium

-- 
You received this bug notification because you are a member of Zorba
Coders, which is the registrant for Zorba.
https://bugs.launchpad.net/bugs/869024

Title:
  Zorba crashes with getReference

Status in Zorba - The XQuery Processor:
  New

Bug description:
  The following query sometimes causes Zorba to crash:

  import module namespace ddl = 
"http://www.zorba-xquery.com/modules/store/dynamic/collections/ddl";;
  import module namespace dml = 
"http://www.zorba-xquery.com/modules/store/dynamic/collections/dml";;
  import module namespace ref = 
"http://www.zorba-xquery.com/modules/node-reference";;

  ddl:create(xs:QName("ddl:coll"));
  dml:insert-nodes-last(xs:QName("ddl:coll"),element {"bb"}{text {"aa"}});
  ref:node-reference(dml:collection(xs:QName("ddl:coll")))

  This is caused by the following cast: 
  const OrdPathNode* n = static_cast<const OrdPathNode*>(node); 
  which is not correct when node is a TextNode

To manage notifications about this bug go to:
https://bugs.launchpad.net/zorba/+bug/869024/+subscriptions

-- 
Mailing list: https://launchpad.net/~zorba-coders
Post to     : zorba-coders@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zorba-coders
More help   : https://help.launchpad.net/ListHelp

Reply via email to