From 09d0149664da35e4c52fc6b8e452e2014a362eca Mon Sep 17 00:00:00 2001 From: Joris Vink Date: Fri, 19 Aug 2005 13:36:51 +0000 Subject: do not close the entries file until all files depending on it have been passed to the callback. ok xsa@ --- usr.bin/cvs/file.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'usr.bin') diff --git a/usr.bin/cvs/file.c b/usr.bin/cvs/file.c index 5774b78515b..bacda35e99c 100644 --- a/usr.bin/cvs/file.c +++ b/usr.bin/cvs/file.c @@ -1,4 +1,4 @@ -/* $OpenBSD: file.c,v 1.115 2005/08/17 16:23:19 joris Exp $ */ +/* $OpenBSD: file.c,v 1.116 2005/08/19 13:36:50 joris Exp $ */ /* * Copyright (c) 2004 Jean-Francois Brousseau * All rights reserved. @@ -604,11 +604,6 @@ cvs_file_loadinfo(char *path, int flags, int (*cb)(CVSFILE *, void *), ((cvs_error = cb(base, arg)) != CVS_EX_OK)) goto fail; - if (entf != NULL) { - cvs_ent_close(entf); - entf = NULL; - } - /* * If we have a normal file, pass it as well. */ @@ -626,6 +621,11 @@ cvs_file_loadinfo(char *path, int flags, int (*cb)(CVSFILE *, void *), } } + if (entf != NULL) { + cvs_ent_close(entf); + entf = NULL; + } + return (base); fail: -- cgit v1.2.3