From bdb81673209f7f52ca5c7105fd9461a4d6c19219 Mon Sep 17 00:00:00 2001 From: Andrea Mazzoleni Date: Sat, 30 Apr 2011 10:56:47 +0200 Subject: [PATCH] Prints loading message before opening the file. --- state.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/state.c b/state.c index 890498cd..7c1636ee 100644 --- a/state.c +++ b/state.c @@ -202,6 +202,9 @@ void state_read(struct snapraid_state* state) content = tommy_list_head(&state->contentlist)->data; pathcpy(path, sizeof(path), content->content); + + printf("Loading state from %s...\n", path); + f = fopen(path, "rt"); if (!f) { /* if not found, assume empty */ @@ -212,8 +215,6 @@ void state_read(struct snapraid_state* state) exit(EXIT_FAILURE); } - printf("Loading state from %s...\n", path); - /* start with a MD5 default. */ /* it's for compatibility with version 1.0 where MD5 was implicit. */ state->hash = HASH_MD5;