diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-07-21 10:52:09 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2015-07-21 10:52:09 +0000 |
commit | 2deaf0340192fdd457b4dcc6eae63ad875a3af6d (patch) | |
tree | a30f3ff3519caf2e4474ee071ba60f9b1f26dbae /cont.c | |
parent | 613d97c5253e8baa7998702c26c0ffdbf56dd3c7 (diff) |
cont.c: CreateFiberEx fallback
* cont.c (fiber_initialize_machine_stack_context): fallback
definition of CreateFiberEx for VC6.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@51315 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'cont.c')
-rw-r--r-- | cont.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -659,6 +659,10 @@ fiber_initialize_machine_stack_context(rb_fiber_t *fib, size_t size) rb_thread_t *sth = &fib->cont.saved_thread; #ifdef _WIN32 +# if defined(_MSC_VER) && _MSC_VER <= 0x1200 +# define CreateFiberEx(cs, stacksize, flags, entry, param) \ + CreateFiber((stacksize), (entry), (param)) +# endif fib->fib_handle = CreateFiberEx(size - 1, size, 0, fiber_entry, NULL); if (!fib->fib_handle) { /* try to release unnecessary fibers & retry to create */ |