fix Issue #544 - WebSocket waitForData timeout doesn't work

- use overloads instead of default parameter

- count down the remaining timeout duration while
  waiting for a new message