unix: silence STATIC_ASSERT compiler warnings

Fix the following two warnings:

  src/unix/core.c:74:1: warning: ISO C90 forbids array
  'static_assert_failed' whose size can't be evaluated [-Wvla]
  src/unix/core.c:76:1: warning: ISO C90 forbids array
  'static_assert_failed' whose size can't be evaluated [-Wvla]
linux: don't use fopen() in uv_resident_set_memory()

RSS is a reflection of the number of pages that a process has mapped.
glibc implements fopen() in terms of mmap() which means that trying
to read the number of mapped pages changes it. Switch to open().
2013.04.24, Version 0.10.5 (Stable)

Changes since version 0.10.4:

* unix: silence STATIC_ASSERT compiler warnings (Ben Noordhuis)

* windows: make timers handle large timeouts (Miroslav Bajtoš)

* windows: remove superfluous assert statement (Bert Belder)

* unix: silence STATIC_ASSERT compiler warnings (Ben Noordhuis)

* linux: don't use fopen() in uv_resident_set_memory() (Ben Noordhuis)
ChangeLog: fix incorrect release date
Now working on v0.10.6
stream: fix osx select hack

After latest twiddling, `stream->io_watcher.fd` doesn't contain a real
stream's file descriptior anymore. The one from `select_state` should be
used instead.

Zero-initialize `select_state->event` field.
stream: fix small nit in select hack, add test
build: link with libkvm on openbsd

The Makefile already did and now the gyp build does too. Fixes the
OpenBSD build of node.js.

Fixes joyent/node#5363.
stream: use harder sync restrictions for osx-hack

Synchronize harder to avoid excessive spins, invokations of async
callback and sporadic assertion failures on double-call of async
callback.
unix: fix EMFILE error handling

On Linux, the accept() and accept4() system calls checks for EMFILE
before checking for EAGAIN. Refine our EMFILE error handling tactic
to deal with that. Here is what used to happen:

 1. The event loop calls accept() and sees EMFILE.

 2. Libuv switches to EMFILE error handling mode. It closes a stashed
    file descriptor and calls accept() again.

 3. The accept() system call fails with EAGAIN.

 4. Libuv reopens the stashed file descriptor (reaching RLIMIT_NOFILE
    again) and returns control to the regular event loop.

 5. The regular event loop calls accept(), sees EMFILE and jumps to
    step 2 again. Effectively an infinite loop.

Avoid that by not calling accept() again when we've seen EAGAIN.

Fixes joyent/node#5389.
Merge remote-tracking branch 'origin/v0.10'

Conflicts:
	ChangeLog
	src/version.c
darwin: fix unnecessary include headers

This file doesn't use any Cocoa functions, CoreFoundation.h is enough here.
This line causes compilation error on iOS environment.
darwin: rename darwin-getproctitle.m

Rename it to darwin-getproctitle.c, it doesn't need an Objective-C
compiler. Fix up -Wpedantic warnings about void to function pointer
casts and include <ApplicationServices/ApplicationServices.h> to get
the GetCurrentProcess() function prototype.
sunos: handle disabled watcher after callback

Fix a potential use-after-free bug where the uv__io watcher struct is
referenced after being disabled by its callback function. The stress
is on 'potential' because in practice the watcher's memory is not
released until the next tick of the event loop.
test: add RETURN_SKIP and RETURN_TODO macros

Added two new flags to identify tests that are intentionally ignored
(usually because we don't want to implement the tested functionality
on current platform) and test serving as TODO list (usually indicating
that the tested functionality should be implemented on current plaform
in the near future.)
Merge remote-tracking branch 'origin/v0.10'

Conflicts:
	ChangeLog
test: fix process_title failing on linux

Shorten the test string from 40 to 38 characters because the title
length is limited to 39 characters.

Truncation of long titles was introduced intentionally by commit
a0c1d84 (see discussion in joyent/node#5006).
test: add error logging to tty unit test
2013.05.11, Version 0.11.2 (Unstable)

Changes since version 0.11.1:

* darwin: look up file path with F_GETPATH (Ben Noordhuis)

* unix, windows: add uv_has_ref() function (Saúl Ibarra Corretgé)

* build: avoid double / in paths for dtrace (Timothy J. Fontaine)

* unix: remove src/unix/cygwin.c (Ben Noordhuis)

* windows: deal with the fact that GetTickCount might lag (Bert Belder)

* unix: silence STATIC_ASSERT compiler warnings (Ben Noordhuis)

* linux: don't use fopen() in uv_resident_set_memory() (Ben Noordhuis)
Now working on v0.11.3