Merge remote-tracking branch 'epatey/master' into epatey
handle unexpected info messages
handle die shutdown and unexpected calls
fix crash in ezk_con_man on end_connection/2

If you check ezk_connection_manager:get_connections() you will get this
result:

 {ok,[{<0.10234.2>,[]},{<0.210.0>,[]},{<0.196.0>,[]}]}

However handle_info expects just a pid and not a tuple.
try to find the culprit by adding is_pid() clauses to calls
add one last extra safety to catch bugs
fix bug, connections are tuples in State
typo
try not to die from telling others to die
Merge branch 'find-connection-bugs' into campanja
again, remove sending to tuples cause it won't work
Merge branch 'find-connection-bugs' into campanja
remove sending to non-pids

crasher:
  initial call: ezk_connection:init/1
  pid: <0.21879.2077>
  registered_name: []
  exception exit: {badarg,
                      [{ezk_connection,'-terminate/2-fun-1-',2,
                           [{file,"src/ezk_connection.erl"},{line,430}]},
                       {dict,map_bucket,2,[{file,"dict.erl"},{line,459}]},
                       {dict,map_bkt_list,2,[{file,"dict.erl"},{line,455}]},
                       {dict,map_bkt_list,2,[{file,"dict.erl"},{line,455}]},
                       {dict,map_seg_list,2,[{file,"dict.erl"},{line,450}]},
                       {dict,map_dict,2,[{file,"dict.erl"},{line,445}]},
                       {ezk_connection,terminate,2,
                           [{file,"src/ezk_connection.erl"},{line,429}]},
                       {gen_server,terminate,6,
                           [{file,"gen_server.erl"},{line,712}]}]}
    in function  gen_server:terminate/6 (gen_server.erl, line 715)
  ancestors: [ezk_connection_manager,ezk_sup,<0.165.0>]
  messages: []
  links: [<0.167.0>,<0.231.0>,#Port<0.603559>]
  dictionary: [{random_seed,{19138,20638,16384}}]
  trap_exit: true
  status: running
Trailing whitespace and tabs are THE DEVIL!
5/10 gen_server:cast in ezk_connection fail

Were causing function_clause crashes.
Regression: Previous fix broke monitoring

refs #1169
Merge branch 'monitor-connection-notfound' into campanja
Fix asymmetric error behaviour

The erlang zookeeper library, ezk, tries to handle errors by monitoring
the erlang process that uses the connection. This is to ensure that the
connection is shutdown if the using process for some reason terminates.
However, if the connection dies by itself, there is no mechanism to inform
the using process that there no longer exists a connection and it will
experience a crash the next time it is executing any ezk commands, since
it uses gen_server:call/3.
Merge branch 'r1711-ezk-asymmetric-error-behaviour'
Merge branch 'master' of https://github.com/campanja/ezk

Conflicts:
	src/ezk.erl
	src/ezk_connection.erl