listening to keyboard&p2p download request

1. correct the port busy issues by assigning dynamic upload port number
to peers not static
2. detect keyboard and p2p download request by creating a thread first
and then do listen the keyboard
resolve the conflict

conflict resolving