mranney/node_redis — pull request #528 by whockey (2013-12-12 20:21:24+00:00)
Title: Make retry vars still hold in an authrization failer

Only resetting the the retry_vars if the connection is actually established. Otherwise the reconnection could infinitely attempt to reconnect on an auth failure regardless of ```max_attempts```, ```retry_delay``` etc.

__Example:__

1. Send in ```max_attempts:5```
2. Redis accepts the socket connection, but rejects at the auth level (invalid auth, max clients etc)
3. ```node_redis``` thought the connection was successful and reset the rety_vars
4. However, ```do_auth``` emits an ```error``` event on a failure auth, which starts a reconnection

This change only resets the retry variables if the connection was actually successful.