diff options
author | Jerry Jelinek <jerry.jelinek@joyent.com> | 2015-02-09 12:45:24 +0000 |
---|---|---|
committer | Jerry Jelinek <jerry.jelinek@joyent.com> | 2015-02-09 12:45:24 +0000 |
commit | bb780ca2a1eb25eea51d290828072c9efbec6ea6 (patch) | |
tree | 11ce1a5719d62426c67f75981fbfb04d41dd4082 /usr/src/tools/ctf | |
parent | 8bf1e4f3b335466afe9b85d761b3822ec8c1a371 (diff) | |
parent | 9ef283481583d677cd2cf5449ef49b90eacc97d4 (diff) | |
download | illumos-joyent-bb780ca2a1eb25eea51d290828072c9efbec6ea6.tar.gz |
[illumos-gate merge]
commit 9ef283481583d677cd2cf5449ef49b90eacc97d4
5261 libm should stop using synonyms.h (fix studio build)
commit ed1591688000a5d179c4ba27793cae55590c55d2
5590 improper use of NULL in tools/protocmp
commit ad0b1ea5d69a45fe23c434277599e315f29a5fca
5589 improper use of NULL in tools/ctf
commit 97a9db610324e7db4393415018e0e737485a94cd
4393 /etc/rpc: 100133 and 100169 should be added
Diffstat (limited to 'usr/src/tools/ctf')
-rw-r--r-- | usr/src/tools/ctf/cvt/ctf.c | 2 | ||||
-rw-r--r-- | usr/src/tools/ctf/cvt/dwarf.c | 2 | ||||
-rw-r--r-- | usr/src/tools/ctf/cvt/output.c | 8 | ||||
-rw-r--r-- | usr/src/tools/ctf/stabs/common/genassym.c | 7 |
4 files changed, 8 insertions, 11 deletions
diff --git a/usr/src/tools/ctf/cvt/ctf.c b/usr/src/tools/ctf/cvt/ctf.c index 1e425758c2..83f09cb43e 100644 --- a/usr/src/tools/ctf/cvt/ctf.c +++ b/usr/src/tools/ctf/cvt/ctf.c @@ -1216,7 +1216,7 @@ decompress_ctf(caddr_t cbuf, size_t cbufsz, caddr_t dbuf, size_t dbufsz) (rc = inflate(&zstr, Z_NO_FLUSH)) != Z_STREAM_END || (rc = inflateEnd(&zstr)) != Z_OK) { warning("CTF decompress zlib error %s\n", zError(rc)); - return (NULL); + return (0); } debug(3, "reflated %lu bytes to %lu, pointer at %d\n", diff --git a/usr/src/tools/ctf/cvt/dwarf.c b/usr/src/tools/ctf/cvt/dwarf.c index e261818d3a..5fdcd35e33 100644 --- a/usr/src/tools/ctf/cvt/dwarf.c +++ b/usr/src/tools/ctf/cvt/dwarf.c @@ -1714,7 +1714,7 @@ static const die_creator_t die_creators[] = { { DW_TAG_variable, DW_F_NOTDP, die_variable_create }, { DW_TAG_volatile_type, 0, die_volatile_create }, { DW_TAG_restrict_type, 0, die_restrict_create }, - { 0, NULL } + { 0, 0, NULL } }; static const die_creator_t * diff --git a/usr/src/tools/ctf/cvt/output.c b/usr/src/tools/ctf/cvt/output.c index f699fbf6d3..90c87dabf3 100644 --- a/usr/src/tools/ctf/cvt/output.c +++ b/usr/src/tools/ctf/cvt/output.c @@ -23,8 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Routines for preparing tdata trees for conversion into CTF data, and * for placing the resulting data into an output file. @@ -466,7 +464,7 @@ write_file(Elf *src, const char *srcname, Elf *dst, const char *dstname, int pad; int i; - if (gelf_newehdr(dst, gelf_getclass(src)) == NULL) + if (gelf_newehdr(dst, gelf_getclass(src)) == 0) elfterminate(dstname, "Cannot copy ehdr to temp file"); gelf_getehdr(src, &sehdr); memcpy(&dehdr, &sehdr, sizeof (GElf_Ehdr)); @@ -482,7 +480,7 @@ write_file(Elf *src, const char *srcname, Elf *dst, const char *dstname, */ if (sehdr.e_phnum != 0) { (void) elf_flagelf(dst, ELF_C_SET, ELF_F_LAYOUT); - if (gelf_newphdr(dst, sehdr.e_phnum) == NULL) + if (gelf_newphdr(dst, sehdr.e_phnum) == 0) elfterminate(dstname, "Cannot make phdrs in temp file"); for (i = 0; i < sehdr.e_phnum; i++) { @@ -616,7 +614,7 @@ write_file(Elf *src, const char *srcname, Elf *dst, const char *dstname, } } - if (gelf_update_shdr(dscn, &shdr) == NULL) + if (gelf_update_shdr(dscn, &shdr) == 0) elfterminate(dstname, "Cannot update sect %s", sname); new_offset = (off_t)shdr.sh_offset; diff --git a/usr/src/tools/ctf/stabs/common/genassym.c b/usr/src/tools/ctf/stabs/common/genassym.c index 9183e52ffd..7c1aa73b7a 100644 --- a/usr/src/tools/ctf/stabs/common/genassym.c +++ b/usr/src/tools/ctf/stabs/common/genassym.c @@ -23,8 +23,6 @@ * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * In this mode, we generate header files containg various #defines which can * be used to access members of various structures, and to walk through arrays. @@ -182,7 +180,8 @@ ga_process_name(char *line) if (shdef != NULL) { ssize_t tsz; - for (shift = -1, tsz = sz; tsz > 0; tsz >>= 1, shift++); + for (shift = -1, tsz = sz; tsz > 0; tsz >>= 1, shift++) + ; if (shift < 0 || 1 << shift != sz) { return (parse_warn("Can't make shift #define: %s size " "(%d) isn't a power of 2", curname, sz)); @@ -273,7 +272,7 @@ ga_member_find(ctf_id_t curtype, ga_member_cb_data_t *md) int rc; if ((c = strchr(md->gmcb_memname, '.')) != NULL) - *c++ = NULL; + *c++ = '\0'; md->gmcb_submem = c; if ((rc = ctf_member_iter(ctf, curtype, ga_member_cb, md)) == 0) { |