warning: assigned but unused variable - tries

This patch tries to use an unused variable tries.