Patch by Chris Clark to set a max number of login retries, so as to prevent entering an infinite loop. This can happen when the cookie is assumed to be valid but doesn't work properly on the server. While this won't fix logins in that situation, it will prevent the infinite loop followed by a "maximum recursion deptch" error.
Patch by Chris Clark to set a max number of login retries, so as to
prevent entering an infinite loop. This can happen when the cookie is
assumed to be valid but doesn't work properly on the server. While this
won't fix logins in that situation, it will prevent the infinite loop
followed by a "maximum recursion deptch" error.

Reviewed at http://reviews.review-board.org/r/879/




haosdent/rbtools,clach04/rbtools,blair/pkg-rbtools,halvorlu/rbtools,reviewboard/rbtools,beol/rbtools,halvorlu/rbtools,Khan/rbtools,clach04/rbtools_0.4.1,datjwu/rbtools,halvorlu/rbtools,datjwu/rbtools,davidt/rbtools,datjwu/rbtools,beol/rbtools,bcelary/rbtools,davidt/rbtools,Khan/rbtools,reviewboard/rbtools,1tush/rbtools,haosdent/rbtools,beol/rbtools,clach04/old_rbtools_0.3.2,haosdent/rbtools,davidt/rbtools,reviewboard/rbtools