Revision: 3613
          http://vexi.svn.sourceforge.net/vexi/?rev=3613&view=rev
Author:   mkpg2
Date:     2009-08-20 15:17:49 +0000 (Thu, 20 Aug 2009)

Log Message:
-----------
Fix. Was possible to lose a JSExn in putAndTriggerTraps.

Modified Paths:
--------------
    trunk/core/org.ibex.js/src/org/ibex/js/Scheduler.java

Modified: trunk/core/org.ibex.js/src/org/ibex/js/Scheduler.java
===================================================================
--- trunk/core/org.ibex.js/src/org/ibex/js/Scheduler.java       2009-08-20 
15:16:35 UTC (rev 3612)
+++ trunk/core/org.ibex.js/src/org/ibex/js/Scheduler.java       2009-08-20 
15:17:49 UTC (rev 3613)
@@ -125,6 +125,7 @@
        
        public void interrupt(){ javathread.interrupt(); }
        
+       public boolean isSchedulerContext(){ return 
javathread==java.lang.Thread.currentThread(); }
        
        ////////////
        // JS
@@ -207,8 +208,12 @@
 
     public void runAfterPut(JSExn e) throws JSExn{
         try{
-            if(jsthread.currentInterpreter.f!=null)
+            if(jsthread.currentInterpreter.f!=null){
                 jsthread.currentInterpreter.run(e);
+            }
+            else{
+               if(e!=null) throw e;
+            }
         }finally{
             if(jsthread.currentInterpreter.old==null) jsthread.destroy();
             else jsthread.currentInterpreter = jsthread.currentInterpreter.old;


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Vexi-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/vexi-svn

Reply via email to