10393 ctf: NULL pointer errors

Review Request #1467 - Created Feb. 11, 2019 and submitted

Information
Toomas Soome
illumos-gate
10393
69ee864...
Reviewers
general
/code/illumos-gate/usr/src/lib/libctf/common/ctf_elfwrite.c: In function 'ctf_wr
ite_elf':
/code/illumos-gate/usr/src/lib/libctf/common/ctf_elfwrite.c:71:44: error: compar
ison between pointer and integer [-Werror]
  if (gelf_newehdr(dst, gelf_getclass(src)) == NULL) {
                                            ^~
/code/illumos-gate/usr/src/lib/libctf/common/ctf_elfwrite.c:111:32: error: compa
rison between pointer and integer [-Werror]
   if (gelf_newphdr(dst, nphdr) == NULL) {
                                ^~
/code/illumos-gate/usr/src/lib/libctf/common/ctf_elfwrite.c:269:37: error: compa
rison between pointer and integer [-Werror]
   if (gelf_update_shdr(dscn, &shdr) == NULL) {
                                     ^~
/code/illumos-gate/usr/src/lib/libctf/common/ctf_elfwrite.c:354:36: error: compa
rison between pointer and integer [-Werror]
  if (gelf_update_ehdr(dst, &dehdr) == NULL) {
                                    ^~

/code/illumos-gate/usr/src/common/ctf/ctf_create.c: In function 'ctf_add_function':
/code/illumos-gate/usr/src/common/ctf/ctf_create.c:1989:14: error: comparison between pointer and integer [-Werror]
  if (symbase == NULL)
              ^~
/code/illumos-gate/usr/src/common/ctf/ctf_create.c: In function 'ctf_add_object':
/code/illumos-gate/usr/src/common/ctf/ctf_create.c:2056:14: error: comparison between pointer and integer [-Werror]
  if (symbase == NULL)
              ^~

cc1: all warnings being treated as errors

  
Andrew Stormont
Robert Mustacchi
Andy Fiddaman
Toomas Soome
Review request changed

Status: Closed (submitted)

Loading...