Subject: Re: [ruby-ffi] access to constants defined in /usr/include/sys/errno.h |
From: Aman Gupta |
Date: 5/6/10 9:04 PM |
To: ruby-ffi@googlegroups.com |
irb(main):015:0> Errno::EWOULDBLOCK::Errno => 35 On Thu, May 6, 2010 at 5:48 PM, Chuck Remes <cremes.devlist@mac.com> wrote:
I need to check a result code from a C function call against some constants defined in /usr/include/sys/errno.h. I know I could define the constant in my ruby module, but I'm not certain that these constants have the same value across platforms. Specifically, I need to check for EWOULDBLOCK and EAGAIN. Is there a way to load these constants during startup (or gem installation)? cr