From a21f92eaa30b57eb353f88e92f39688700d04dcc Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Wed, 24 Oct 2007 12:49:16 +0200 Subject: [PATCH] afs.c: Fix open_afs_tables(). The old code tried to close the table we just failed to open. We just want to close all tables that were opened successfully before the failed one. --- afs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/afs.c b/afs.c index c410854c..d889ec77 100644 --- a/afs.c +++ b/afs.c @@ -684,12 +684,12 @@ static int open_afs_tables(void) continue; PARA_ERROR_LOG("%s init: %s\n", afs_tables[i].name, PARA_STRERROR(-ret)); + break; } if (ret >= 0) return ret; - do - afs_tables[i].close(); - while (i--); + while (i) + afs_tables[--i].close(); return ret; } -- 2.39.2