github
Advanced Search
  • Home
  • Pricing and Signup
  • Explore GitHub
  • Blog
  • Login

codeslinger / sendfile

  • Admin
  • Watch Unwatch
  • Fork
  • Your Fork
  • Pull Request
  • Download Source
    • 8
    • 0
  • Source
  • Commits
  • Network (0)
  • Issues (0)
  • Downloads (0)
  • Wiki (1)
  • Graphs
  • Branch: master

click here to add a description

click here to add a homepage

  • Branches (1)
    • master ✓
  • Tags (0)
Sending Request…
Enable Donations

Pledgie Donations

Once activated, we'll place the following badge in your repository's detail box:
Pledgie_example
This service is courtesy of Pledgie.

Ruby interface to sendfile(2) system call — Read more

  cancel

  cancel
  • Private
  • Read-Only
  • HTTP Read-Only

This URL has Read+Write access

tuned up the README 
codeslinger (author)
Sat Dec 27 10:22:43 -0800 2008
commit  3cd8a41d190a5a65a120c07f75eb4ec6d5e5436a
tree    21526cd2747a43e3972f065623e043160775b194
parent  3f5350a3f1e4d4366fd0df36086a2bddff867059
sendfile /
name age
history
message
file ChangeLog Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
file FILES Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
file LICENSE Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
file README.textile Sat Dec 27 10:22:43 -0800 2008 tuned up the README [codeslinger]
directory ext/ Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
file sendfile.gemspec Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
directory test/ Sat Dec 27 10:11:11 -0800 2008 initial entry into GitHub [codeslinger]
README.textile

Ruby sendfile(2) Interface

This module allows Ruby programs to access their OS’s native
sendfile(2) system call from any IO object. Your kernel must
export a recognized signature for the sendfile(2) system call
to use this module. Currently, that includes Linux, Solaris
and FreeBSD.

Installation

Download and install the latest package from the rubyforge.org
RubyGems repository.

$ sudo gem install sendfile

If the tests all pass, you’re ready to start using sendfile.

Usage

Here’s a small example of a use of IO#sendfile.

require ‘socket’ require ‘rubygems’ require ‘sendfile’ s = TCPSocket.new ‘yourdomain.com’, 5000 File.open ‘somefile.txt’ { |f| s.sendfile f } s.close

See the test scripts for more examples on how to use this
module.

Blog | Support | Training | Contact | API | Status | Twitter | Help | Security
© 2010 GitHub Inc. All rights reserved. | Terms of Service | Privacy Policy
Powered by the Dedicated Servers and
Cloud Computing of Rackspace Hosting®
Dedicated Server