Further reduce a potential timing sensitivity

git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@1515778 13f79535-47bb-0310-9956-ffa450edef68
Add the rather crucial missing i++ in the wait loop

git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@1515779 13f79535-47bb-0310-9956-ffa450edef68