On Wed, Jul 05, 2000 at 03:05:35PM +0100, [EMAIL PROTECTED] wrote:
> The attached patch implements the current() function in Sablotron.
> It works for me, but I haven't tested it comprehensively.

I found a bug (when used in conjunction with the document() function)
and here is a fix:

--- Sablot-0.40/Sablot/expr.cpp Fri Jun 30 11:23:25 2000
+++ Sablot-0.40-patched/Sablot/expr.cpp Thu Jul  6 19:01:57 2000
@@ -2662,6 +2665,10 @@
             DStr location;
             Tree *newtree;
             Context *newc = new Context;
+
+            // Current node doesn't change
+            newc->setCurrentNode (c->getCurrentNode());
+
             if (atoms[0] -> type == EX_NODESET)
             {
                 const Context& ctxt = atoms[0] -> tonodesetRef();

Reply via email to