Fix identity handling for inproc transport

Fixes #872

Backport of hurtonm/libzmq@a09407829; included as
zeromq/libzmq@e376ad278 in development repos.
Merge pull request #79 from olafmandel/master

Fix identity handling for inproc transport
Add failing test reproducing issue #1015.

There is a race condition when connect and bind on a new inproc
endpoint happen "simultaneously" in threads.  Causes the error:
  Assertion failed: ok (ctx.cpp:474)

This is a backport of libzmq:5cf74db6b
by Joe Eli McIlvain <joe.eli.mac@gmail.com>
Fix race condition in connecting inproc sockets

This is a backport of libzmq:3678c32b9
by Martin Hurton <hurtonm@gmail.com>
Merge pull request #81 from olafmandel/issue_1015

Backport of test and fix for zeromq/libzmq#1015
Updated NEWS
Updated for #1015
Merge pull request #82 from hintjens/master

Updated NEWS