Changeset 14640 for trunk/FACT++


Ignore:
Timestamp:
11/17/12 15:33:57 (12 years ago)
Author:
tbretz
Message:
Fixed a problem with the onchange of services because the return value of ConvertEvent had changed; fixed a problem with proceeding excution of the exit()-calling thread.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/FACT++/src/InterpreterV8.cc

    r14639 r14640  
    8787{
    8888    V8::TerminateExecution(fThreadId);
    89     return Undefined();
     89
     90    // we have to throw an excption to make sure that the
     91    // calling thread does not go on executing until it
     92    // has realized that it should terminate
     93    return ThrowException(Null());
    9094}
    9195
     
    10171021
    10181022    // -------------------------------------------------------------------
     1023
    10191024    TryCatch exception;
    10201025
     
    10231028
    10241029    Handle<Value> ret = ConvertEvent(&evt, cnt, service.c_str());
    1025     if (ret->IsArray())
    1026     {
    1027         Handle<Array> data = Handle<Array>::Cast(ret);
    1028         Handle<Value> args[] = { data };
    1029 
    1030         Handle<Function>::Cast(val)->Call(obj, 1, args);
    1031     }
     1030    if (ret->IsObject())
     1031        Handle<Function>::Cast(val)->Call(obj, 1, &ret);
    10321032
    10331033    fThreadIds.erase(id);
Note: See TracChangeset for help on using the changeset viewer.