diff options
Diffstat (limited to 'usr/src/tools/ctf')
| -rw-r--r-- | usr/src/tools/ctf/cvt/dwarf.c | 9 | 
1 files changed, 5 insertions, 4 deletions
| diff --git a/usr/src/tools/ctf/cvt/dwarf.c b/usr/src/tools/ctf/cvt/dwarf.c index a7e97dfb23..ce8f6f9601 100644 --- a/usr/src/tools/ctf/cvt/dwarf.c +++ b/usr/src/tools/ctf/cvt/dwarf.c @@ -23,8 +23,6 @@   * Use is subject to license terms.   */ -#pragma ident	"%Z%%M%	%I%	%E% SMI" -  /*   * DWARF to tdata conversion   * @@ -1832,8 +1830,11 @@ dw_read(tdata_t *td, Elf *elf, const char *filename)  	}  	if ((rc = dwarf_next_cu_header(dw.dw_dw, &hdrlen, &vers, &abboff, -	    &addrsz, &nxthdr, &dw.dw_err)) != DW_DLV_OK || -	    (cu = die_sibling(&dw, NULL)) == NULL || +	    &addrsz, &nxthdr, &dw.dw_err)) != DW_DLV_OK) +		terminate("file does not contain valid DWARF data: %s\n", +		    dwarf_errmsg(dw.dw_err)); + +	if ((cu = die_sibling(&dw, NULL)) == NULL ||  	    (child = die_child(&dw, cu)) == NULL)  		terminate("file does not contain dwarf type data "  		    "(try compiling with -g)\n"); | 
