Squashed 'src/leveldb/' changes from be1b0ff..936b461

936b461 Merge upstream LevelDB 1.13.
748539c LevelDB 1.13

git-subtree-dir: src/leveldb
git-subtree-split: 936b4613ea4551992e6096b1e05eeefc09a20e3b
Merge src/leveldb changes for LevelDB 1.13
Added ping time measurement.
New RPC "ping" command to request ping.
Implemented "pong" message handler.
New "pingtime" field in getpeerinfo, to provide results to user.
New "pingwait" field, to show pings still in flight, to better see newly lagging peers.
make fCommandLine a local variable in AppInit()
Remove include of windows.h from allocators.h

Create an allocators.cpp, and move all of the #ifdef WIN32
code and the #include of windows.h into it.

Two motives for this cleanup:
1. I'm getting a weird error in windows.h in my smartfee branch.
2. allocators.h is included (indirectly) just about everywhere, so
this should speed up Windows compiles quite a lot.
Merge pull request #3066 from Diapolo/rem_global

make fCommandLine a local variable in AppInit()
Rework pull-tester scripts, disable blockchain tester

Re-organize the pull-tester scripts a bit.

And disables running the blockchain tester, it is not working properly
on the pull-tester machine for reasons I cannot explain (fails to start).
Disable code-coverage builds for now

Not working on the pull-tester machine, 'make cov' hangs there.
Merge pull request #3078 from gavinandresen/pulltester

Rework pull-tester scripts, disable blockchain tester
Merge pull request #3071 from gavinandresen/windows_h

Remove include of windows.h from allocators.h
prevent compiler redefinition warnings

- I observed a massive amount of redefinition warnings after #3071, which
  are silenced by this patch
- uses the same style as we do in other places, where we define _WIN32_WINNT
Merge pull request #3081 from Diapolo/silence_compiler

prevent compiler redefinition warnings
Refactor/encapsulate chain globals into a CChain class
Merge pull request #2937

971bb3e Added ping time measurement. New RPC "ping" command to request ping. Implemented "pong" message handler. New "pingtime" field in getpeerinfo, to provide results to user. New "pingwait" field, to show pings still in flight, to better see newly lagging peers. (Josh Lehan)
[doc] Add testnet hidden service port to the example tor config.

Seems like there are a lot of advertised testnet HS nodes that
don't actually work. Lack of the testnet port on the example
HS config might be one reason.
Merge pull request #3089 from gmaxwell/hsport

[doc] Add testnet hidden service port to the example tor config.
Merge pull request #2933 from sipa/leveldb113

Merge upstream LevelDB 1.13
Merge pull request #3077 from sipa/chain

Refactor/encapsulate chain globals into a CChain class
Avoid core dump if rpc port is in use.

The cleanup code needs to check for NULL rpcworkers thread group.