$OpenBSD: patch-bzip2recover_c,v 1.1 2016/06/28 09:56:23 jasper Exp $

CVE-2016-3189 bzip2: heap use after free in bzip2recover
Patch from: https://bugzilla.redhat.com/show_bug.cgi?id=1319648

--- bzip2recover.c.orig	Tue Jun 28 11:54:25 2016
+++ bzip2recover.c	Tue Jun 28 11:54:43 2016
@@ -457,6 +457,7 @@ Int32 main ( Int32 argc, Char** argv )
             bsPutUChar ( bsWr, 0x50 ); bsPutUChar ( bsWr, 0x90 );
             bsPutUInt32 ( bsWr, blockCRC );
             bsClose ( bsWr );
+	    outFile = NULL;
          }
          if (wrBlock >= rbCtr) break;
          wrBlock++;
