raindrops.git about / heads / tags real-time stats for preforking Rack servers
blob 3a0100fcfc4eb6b7a6c843d8903257b233d0ec3a 303 bytes (raw) $ git show HEAD:ext/raindrops/my_fileno.h # shows this blob on the CLI
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
#include <ruby.h> #include <ruby/io.h> #ifdef HAVE_RB_IO_DESCRIPTOR # define my_fileno(io) rb_io_descriptor(io) #else /* Ruby <3.1 */ static int my_fileno(VALUE io) { rb_io_t *fptr; GetOpenFile(io, fptr); rb_io_check_closed(fptr); return fptr->fd; } #endif /* Ruby <3.1 !HAVE_RB_IO_DESCRIPTOR */
git clone https://yhbt.net/raindrops.git