Fixing a bug in latest selective retry code