Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 21 Oct 2008 12:10:31 +0000 (UTC)
From:      Dag-Erling Smorgrav <des@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r184123 - head/lib/libarchive
Message-ID:  <200810211210.m9LCAVuu098676@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: des
Date: Tue Oct 21 12:10:30 2008
New Revision: 184123
URL: http://svn.freebsd.org/changeset/base/184123

Log:
  Move va_end() up

Modified:
  head/lib/libarchive/archive_util.c

Modified: head/lib/libarchive/archive_util.c
==============================================================================
--- head/lib/libarchive/archive_util.c	Tue Oct 21 11:58:26 2008	(r184122)
+++ head/lib/libarchive/archive_util.c	Tue Oct 21 12:10:30 2008	(r184123)
@@ -168,6 +168,7 @@ archive_set_error(struct archive *a, int
 
 	va_start(ap, fmt);
 	archive_string_vsprintf(&(a->error_string), fmt, ap);
+	va_end(ap);
 	if (error_number > 0) {
 		archive_strcat(&(a->error_string), ": ");
 #ifdef HAVE_STRERROR_R
@@ -184,7 +185,6 @@ archive_set_error(struct archive *a, int
 		archive_strcat(&(a->error_string), errp);
 	}
 	a->error = a->error_string.s;
-	va_end(ap);
 }
 
 void



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200810211210.m9LCAVuu098676>