浏览代码

Make LibuvEventPoll compatible with the latest libuv again

Nils Maier 10 年之前
父节点
当前提交
3f2b5dce2f
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/LibuvEventPoll.cc

+ 2 - 2
src/LibuvEventPoll.cc

@@ -66,7 +66,7 @@ namespace {
     delete reinterpret_cast<T*>(handle);
   }
 
-#if !defined(UV_VERSION_MINOR) || UV_VERSION_MINOR <= 10
+#if !defined(UV_VERSION_MINOR) || (UV_VERSION_MAJOR == 0 && UV_VERSION_MINOR <= 10)
 
   static void timer_callback(uv_timer_t* handle, int status)
   {
@@ -78,7 +78,7 @@ namespace {
     timer_callback(handle, 0);
   }
 
-#else // !defined(UV_VERSION_MINOR) || UV_VERSION_MINOR <= 10
+#else // !defined(UV_VERSION_MINOR) || (UV_VERSION_MAJOR == 0 && UV_VERSION_MINOR <= 10)
 
   static void timer_callback(uv_timer_t* handle)
   {