Ran into this when trying to build subversion with the default ulimit -n of 128.
ok? Index: devel/swig/Makefile =================================================================== RCS file: /cvs/ports/devel/swig/Makefile,v retrieving revision 1.60 diff -u -p -r1.60 Makefile --- devel/swig/Makefile 21 Jul 2015 03:27:25 -0000 1.60 +++ devel/swig/Makefile 9 Apr 2017 21:54:50 -0000 @@ -4,7 +4,7 @@ COMMENT = simplified wrapper and interfa SUBST_VARS = VERSION VERSION = 2.0.11 -REVISION = 2 +REVISION = 3 DISTNAME = swig-${VERSION} CATEGORIES = devel Index: devel/swig/patches/patch-Source_Swig_include_c =================================================================== RCS file: devel/swig/patches/patch-Source_Swig_include_c diff -N devel/swig/patches/patch-Source_Swig_include_c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ devel/swig/patches/patch-Source_Swig_include_c 9 Apr 2017 21:54:50 -0000 @@ -0,0 +1,11 @@ +$OpenBSD$ +--- Source/Swig/include.c.orig Sun Sep 15 16:11:43 2013 ++++ Source/Swig/include.c Sun Apr 9 23:01:00 2017 +@@ -291,6 +291,7 @@ int Swig_insert_file(const_String_or_char_ptr filename + while ((nbytes = Read(f, buffer, 4096)) > 0) { + Write(outfile, buffer, nbytes); + } ++ fclose(f); + return 0; + } +