pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/pkgtools/cwrappers cwrappers-20150318: Don't ferror() ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/88c94d4754fc
branches:  trunk
changeset: 648758:88c94d4754fc
user:      jperkin <jperkin%pkgsrc.org@localhost>
date:      Wed Mar 18 15:05:35 2015 +0000

description:
cwrappers-20150318: Don't ferror() after fclose().

Fixes libtool cwrapper on Linux, ok joerg@

diffstat:

 pkgtools/cwrappers/Makefile                  |  4 ++--
 pkgtools/cwrappers/files/bin/fixup-libtool.c |  7 ++++---
 2 files changed, 6 insertions(+), 5 deletions(-)

diffs (33 lines):

diff -r bd026af495f0 -r 88c94d4754fc pkgtools/cwrappers/Makefile
--- a/pkgtools/cwrappers/Makefile       Wed Mar 18 15:04:35 2015 +0000
+++ b/pkgtools/cwrappers/Makefile       Wed Mar 18 15:05:35 2015 +0000
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.8 2015/03/17 18:39:45 jperkin Exp $
+# $NetBSD: Makefile,v 1.9 2015/03/18 15:05:35 jperkin Exp $
 
-PKGNAME=               cwrappers-20150317
+PKGNAME=               cwrappers-20150318
 CATEGORIES=            pkgtools sysutils
 
 MAINTAINER=            joerg%NetBSD.org@localhost
diff -r bd026af495f0 -r 88c94d4754fc pkgtools/cwrappers/files/bin/fixup-libtool.c
--- a/pkgtools/cwrappers/files/bin/fixup-libtool.c      Wed Mar 18 15:04:35 2015 +0000
+++ b/pkgtools/cwrappers/files/bin/fixup-libtool.c      Wed Mar 18 15:05:35 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: fixup-libtool.c,v 1.4 2014/12/30 15:13:20 wiz Exp $ */
+/* $NetBSD: fixup-libtool.c,v 1.5 2015/03/18 15:05:36 jperkin Exp $ */
 
 /*-
  * Copyright (c) 2009 Joerg Sonnenberger <joerg%NetBSD.org@localhost>.
@@ -390,8 +390,9 @@
        }
        free(line);
 
-       fclose(fp);
-       if (ferror(fp) || fclose(output) || rename(tmp_name, lafile)) {
+       if (ferror(fp) || fclose(fp) ||
+           ferror(output) || fclose(output) ||
+           rename(tmp_name, lafile)) {
                unlink(tmp_name);
                err(255, "output processing failed");
        }               



Home | Main Index | Thread Index | Old Index