More syntax errors plus passOnSearch test fix

Fixed more stupid syntax errors. Also fixed PassOnSearchTest so that the
mock nodes actually accept the incoming connections.
Stupid syntax error fix

Why do I need to take out the parentheses anyway?
Fixed another stupid syntax error

PassOnSearchTest now passes unit test. Testing still hangs on completion
and has a disturbing amount of socket errors.
Fixed disconnection test, now passes

Still hangs at end of test. Still unexpected socket and timeout errors.
Bleh.
Added a lot of exception handling

P2PNode now gracefully shuts down instead of throwing a fit when it hits
socket errors. Theoretically.
Killed last of outside-test errors

A P2PNode's connection thread now checks if its ID is actually in the
node's connection dictionary before trying to delete it.
Fixed another syntax error

Now no outside-test errors or in-test errors, only failures. Still hangs
after testing because of course it does.
Unit tests pass

All P2PNode unit tests now pass. Still hangs after test completion
because of course it does. *headdesk*
Unit test now checks shutdown properly

Shutdown unit test previously only checked if the node's shutdown flag
was true. Now it checks the flags of all possibly running threads.
Added shutdown flag changes

P2PNode.shutdown() now properly sets shutdown flags on all threads.
Naturally this actually made things worse.