Add wrappers to blocking functions and callbacks in order to release
the GVL of ruby 1.9 as long as not in ruby code.

This allowes better concurrency in threaded applications.
Avoid fork() in specs.

fork() is not implemented on windows and jruby.

On Rubinius fork() blocks in these tests or raises 'server closed
the connection unexpectedly' after the test.
Refactor different variants of waiting for the connection socket.

Reduce the 4 variants of waiting to only 2 which are used by both

This also fixes 'Bad file descriptor' respectively wrong behaviour
of #wait_for_notify() on Windows and fixes timeout handling of

Make use of rb_thread_fd_select() on Ruby 1.9, to avoid deprecation
warnings on rb_thread_select().
Fix race in threading spec.
conn#socket() can not be used with IO.for_fd() on Windows.
Link the travis build status icon to ged's repository.
Free memory allocated per rb_fd_init().
adding PG::Result#each_row for looping over result sets by row
Make source settings override TM2 defaults

--HG--
extra : rebase_source : 6397e760c543a57c2e3cbcce7e23df482060d5ef
Merge pull request #4 from larskanis/for_ged

A bunch of cool stuff from Lars Kanis.
Update the History file.
Remove unused variable.
Update Manifest file.
Merge pull request #5 from larskanis/for_ged_2

Update History+Manifest files
Merge with github mirror
Whitespace/docs fix
Add @tenderlove's patch credit to History, reworded some stuff
Add PG::Connection#socket_io to return a memoized IO for the underlying socket.

This keeps the IO in scope until the Connection is garbage-collected, preventing
Ruby from auto-closing the connection to PostgreSQL.
Add experimental -rpath to the LDFLAGS
Split the dual-mode PG::Connection#exec into #exec and #exec_params.

PG::Connection#exec should be backward compatible with old code: it just passes
control to #exec_params directly instead of calling PQexecParams() itself.

Thanks to Aaron Patterson for the idea.