bound the time waiting for analysis to complete

BUG=
R=paulberry@google.com

Review URL: https://codereview.chromium.org//790743003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge@42228 260f80e4-7a28-3924-810f-c04153c831b5
skip completion if client closed stream

BUG=
R=paulberry@google.com

Review URL: https://codereview.chromium.org//774033003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge@42229 260f80e4-7a28-3924-810f-c04153c831b5