Skip to content
Snippets Groups Projects
  • Jakub Jelinek's avatar
    d4c32e1d
    re PR pch/13675 (#including a precompiled header more than once in the same unit fails) · d4c32e1d
    Jakub Jelinek authored
    	PR pch/13675
    	* files.c (struct _cpp_file): Remove pch field.
    	(pch_open_file): Don't set file->pch, just file->pchname.
    	(should_stack_file): After pfile->cb.read_pch call
    	free pchname and clear pchname, don't close file->fd.
    	Test file->pchname instead of file->pch.  Don't close fd after cb.
    	(_cpp_stack_include): Test file->pchname instead of file->pch.
    
    	* c-pch.c (c_common_read_pch): On error close (fd) resp. fclose (f).
    
    From-SVN: r133790
    d4c32e1d
    History
    re PR pch/13675 (#including a precompiled header more than once in the same unit fails)
    Jakub Jelinek authored
    	PR pch/13675
    	* files.c (struct _cpp_file): Remove pch field.
    	(pch_open_file): Don't set file->pch, just file->pchname.
    	(should_stack_file): After pfile->cb.read_pch call
    	free pchname and clear pchname, don't close file->fd.
    	Test file->pchname instead of file->pch.  Don't close fd after cb.
    	(_cpp_stack_include): Test file->pchname instead of file->pch.
    
    	* c-pch.c (c_common_read_pch): On error close (fd) resp. fclose (f).
    
    From-SVN: r133790