Squashed commit of the following:

commit df9fa75817eafd1f89a519ab1ae165fe190a5694
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Fri Nov 30 16:07:53 2012 +0900

    * various fix for datagram connection handling
    - fix bug that datagram listener creation error check is wrong
    - do not call connect for client udp connection (sender gives address to sendto)
    - change handler::socket::state_change WAITACCEPT assertion condition (for datagram)
    - seperate open_datagram_server to init_datagram_server and open_datagram_server, because some initialization only need to done once

    * various fix for timer and timed RPC related bug
    - argument order is reversed for yue.timer

    * make all test pass under test/lua

commit e9dbfb32753252eb86e5d3df0974d56407ca5b4f
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Tue Nov 20 00:07:44 2012 +0900

    fix bug of a few test
    change API emitter:bind, wait, unbind to return emitter itself
    fix bug that timed_ RPC prefix not work
    fix bug that fiber timeout check interval not correct

commit e65bb8e9da20ea50b0f40924e157ba9421e9844e
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Thu Nov 29 20:23:27 2012 +0900

    - reduce number of test (not support current system)
    - fix yue.client bug and yue.fiber:result()

commit 90b79bba5d9b823c6b86d50bb94e24158d2acef5
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Thu Nov 29 12:47:07 2012 +0900

    - change on_read return value condition because first handshake event is no more assure that connection close is done in another place
    - block same function bind specified event more than twice

commit 0b885148bee7e1b35bbf5c86a754d2e5869caf54
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Mon Nov 19 08:26:02 2012 +0900

    - fix socket::close not worked correctly in epoll environment
    - fix callback list not execute all callbacks in it
    - change watcher.lua test

commit c51a1a5a9034478dcf7d57d51ed46b8d7673420d
Merge: 92c0f80 c4098ff
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sun Nov 18 21:22:51 2012 +0900

    Merge remote branch 'origin/feature/pass_test' into feature/pass_test

commit c4098ff5954a19d3617ad2c5411bbe6b704a5d21
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Wed Nov 28 20:06:47 2012 +0900

    - fix finalize process when yue loaded as lua module
    - push error when various coroutine::start fails before function resumes
    - improve and bug fix for callback list object
    - use serpent de/serializer as pritty printer if available
    - fix bug that if client receives websocket handshake packet and frame packet, data not received correctly

commit 92c0f8016935bda7035bcb6a01ba5aad2703508a
Merge: 392af9f d9a3843
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sun Nov 18 21:21:06 2012 +0900

    Merge branch 'feature/lua_client' of github.com:umegaya/yue into feature/pass_test

commit d9a3843feceaa61f04ca7a8c1dc06a229944463d
Merge: 30e0677 6789437
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Wed Nov 28 11:50:37 2012 +0900

    Merge branch 'feature/lua_client' of github.com:umegaya/yue into feature/lua_client

commit 30e0677cba8a711440319acf2ca1292255369eeb
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Sun Nov 25 19:32:35 2012 +0900

    - fix bug that stack corrupted when calculated web socket Sec-Accept-Key
    - fix typo in index.html (x windows => o window)
    - fix bug that selector::init_event forget to initialize event flags (for kqueue)

commit 6193a05aaf00f8c5894cf4721cf64ff71016d307
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Sat Nov 24 22:08:30 2012 +0900

    - fix bug that timeout setting for wait, bind, various call (socket, thread, peer) is not correct (it should be treat as sec but treat as usec)
    - add run mode of yue (debug release)
    - fix compilation error on release build

commit e11ec8b2a3b0ae25fa68ed02211c7d82107c32f7
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Sat Nov 24 09:57:41 2012 +0900

    various bug fix and complete implementation of features
    - delete assertion emittable::remove_watch_entry (because it appears to occur)
    - fix wrongly casted type in emittable::command::fin
    - refine fiber error propagation, now all error including non-lua runtime error,  once catched in lua code
    - make generic emit work
    - adding emittable pointer null check for all lib.yue_{some emitter}_{action} cfunctions
    - change condition for when unref socket on close event is emitted
    - rename constant in yue.lua
    - implement emittable:emit in yue.lua
    - fix bug about cached socket object creation in yue.lua (never consider the case that yue_socket_new returns same pointer more than twice)
    - make yue.fiber work
    - now util::map can remove its element from allocated pointer (previously key is required to remove elem)
    - change default value for util::debug::bt

commit 8c8d41be0f95a81d9ad28b48e27ebf9098d06fa3
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Wed Nov 21 19:51:28 2012 +0900

    fix bug that client connection not working correctly

commit 1fde5cef6e643214163dff814bcf3dc682e5032d
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Wed Nov 21 11:32:45 2012 +0900

    fix bug that socket closed twice when accept watcher closes socket immediately
    index.html can receive parameter of server hostname

commit 392af9f4cbc2bcce70754e2c6842e8f0a41332ed
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sun Nov 18 15:57:27 2012 +0900

    temporary commit

commit 67894377973eeefeac094a7dc5dd1c4cd0841557
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sat Nov 17 19:40:31 2012 +0900

    fix gcc 4.4.6 release build error
    fix bug that if socket::close called before first handshake request done, closed event occurs twice.
    fix URL parameter parse error (index.html)

commit bfdcc12ec6c2d7eb1648eff376c2f46a0b800db7
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sat Nov 17 11:32:25 2012 +0900

    osx: add nice trick to make handler::socket::close thread safe

commit 1e625e55e13a8a471b8c3be90c94a503e66b0490
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Sat Nov 17 07:26:07 2012 +0900

    enable yue.util module
    add some bug fix

commit 26a4efbe789787e7d00a8d132e1a0a8c4f9d82c9
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Fri Nov 16 20:07:36 2012 +0900

    fix assertion when suddenly connection shutdown occurs and un-responsed fiber got timeout

commit 61983068468b5691a9c40bba18212a02e7405fda
Author: tiyatomi <tiyatomi@zynga.com>
Date:   Mon Nov 19 19:51:37 2012 +0900

    change way to call rpc (emittable.procs.func(arg1, arg2, ..., argN)
    fix bug that assertion raise because of accept watcher and handshake process run concurrently

commit 4bc334f419c98d4910bc6066ecc04a661effef00
Author: iyatomi takehiro <iyatomi@gmail.com>
Date:   Fri Nov 16 18:55:31 2012 +0900

    add initial implementation of yue.fiber
    refine generic fiber execution system
    delete peer.hpp
fix watcher.lua error
make yue.client:exit never return
Merge pull request #5 from umegaya/feature/lua_client_pr

Squashed commit of the following: watcher.lua is last one make some error, and make it pass test, so all the task for lua_client finished (except if yue loaded as module of luajit in mac osx, it crushes), so it will merged