[Rpm-maint] Patch: fix segfault in spec file parser

Michael Schroeder mls at suse.de
Fri Apr 9 13:20:58 UTC 2010


readLineFromOFI may modify the fileStack, thus we have to re-set
ofi after calling it

--- build/parseSpec.c.orig	2010-02-15 11:49:29.000000000 +0000
+++ build/parseSpec.c	2010-02-24 10:38:25.000000000 +0000
@@ -283,6 +283,7 @@ int readLine(rpmSpec spec, int strip)
     retry:
 	if ((rc = readLineFromOFI(spec, ofi)) != 0)
 	    return rc;
+	ofi = spec->fileStack;
 
 	/* Copy next file line into the spec line buffer */
 	rc = copyNextLineFromOFI(spec, ofi);


More information about the Rpm-maint mailing list