ensure InterruptedException handling

Do we want to break if this thread is interrupted? This would prevent the nulling out of the `server` reference which happens a few lines below.