Fix pbkdf2.js infinite loop

On simple inspection this looks wrong... haven't tested!