Private
Public Access
2
0

gpio.hpp: added HandleScope creation for Node 4+

Closes #387.

Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
This commit is contained in:
Alex Tereschenko
2016-02-29 00:36:31 +01:00
committed by Brendan Le Foll
parent 389d0ceafd
commit 350a6489ee

View File

@@ -136,6 +136,9 @@ class Gpio
static void
v8isr(uv_work_t* req, int status)
{
#if NODE_MODULE_VERSION >= 0x000D
v8::HandleScope scope(v8::Isolate::GetCurrent());
#endif
mraa::Gpio* This = (mraa::Gpio*) req->data;
int argc = 1;
v8::Local<v8::Value> argv[] = { SWIGV8_INTEGER_NEW(-1) };