From 61080b04dd2fe74b70d413cb31e9197713bb0762 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Wed, 5 Apr 2006 02:02:36 +0000 Subject: [PATCH] Remove mf_unlink_name --- bfile/commit.c | 4 ++-- bfile/mfile.c | 14 ++++---------- bfile/mfile.h | 7 +------ 3 files changed, 7 insertions(+), 18 deletions(-) diff --git a/bfile/commit.c b/bfile/commit.c index 91debc1..992f4dd 100644 --- a/bfile/commit.c +++ b/bfile/commit.c @@ -1,4 +1,4 @@ -/* $Id: commit.c,v 1.25 2005-04-15 10:47:47 adam Exp $ +/* $Id: commit.c,v 1.26 2006-04-05 02:02:36 adam Exp $ Copyright (C) 1995-2005 Index Data ApS @@ -31,7 +31,7 @@ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA #define CF_OPTIMIZE_COMMIT 0 -void cf_unlink (CFile cf) +void cf_unlink(CFile cf) { if (cf->bucket_in_memory) { diff --git a/bfile/mfile.c b/bfile/mfile.c index ce4279a..54a2a82 100644 --- a/bfile/mfile.c +++ b/bfile/mfile.c @@ -1,4 +1,4 @@ -/* $Id: mfile.c,v 1.62 2005-06-14 20:28:53 adam Exp $ +/* $Id: mfile.c,v 1.63 2006-04-05 02:02:36 adam Exp $ Copyright (C) 1995-2005 Index Data ApS @@ -437,7 +437,7 @@ int mf_close(MFile mf) { int i; - yaz_log (YLOG_DEBUG, "mf_close(%s)", mf->name); + yaz_log (YLOG_DEBUG, "mf_close(%s) unlink=%d", mf->name, mf->unlink_flag); assert(mf->open); for (i = 0; i < mf->no_files; i++) { @@ -604,7 +604,9 @@ int mf_write(MFile mf, zint no, int offset, int nbytes, const void *buf) int mf_unlink(MFile mf) { if (mf->open) + { mf->unlink_flag = 1; + } else { int i; @@ -614,11 +616,3 @@ int mf_unlink(MFile mf) return 0; } -/* - * Unlink the file by name, rather than MFile-handle. File should be closed. - */ -int mf_unlink_name(MFile_area ma, const char *name) -{ - abort(); - return 0; -} diff --git a/bfile/mfile.h b/bfile/mfile.h index 2a9205b..eece9ce 100644 --- a/bfile/mfile.h +++ b/bfile/mfile.h @@ -1,4 +1,4 @@ -/* $Id: mfile.h,v 1.2 2005-01-15 19:38:18 adam Exp $ +/* $Id: mfile.h,v 1.3 2006-04-05 02:02:37 adam Exp $ Copyright (C) 1995-2005 Index Data ApS @@ -145,11 +145,6 @@ int mf_unlink(MFile mf); */ void mf_reset(MFile_area ma); -/* - * Unlink the file by name, rather than MFile-handle. - */ -int mf_unlink_name(MFile_area, const char *name); - YAZ_END_CDECL #endif -- 1.7.10.4