Actions
Bug #11986
closedlibproc: cast between incompatible function types
Start date:
Due date:
% Done:
100%
Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:
Description
Build errors with gcc 8:
../common/Psymtab.c: In function 'Psymbol_iter_by_lmid': ../common/Psymtab.c:2912:19: error: cast between incompatible function types from 'int (*)(void *, const GElf_Sym *, const char *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *)'} to 'int (*)(void *, const GElf_Sym *, const char *, const prsyminfo_t *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *, const struct prsyminfo *)'} [-Werror=cast-function-type] PRO_NATURAL, (proc_xsym_f *)func, cd)); ^ ../common/Psymtab.c: In function 'Psymbol_iter': ../common/Psymtab.c:2920:19: error: cast between incompatible function types from 'int (*)(void *, const GElf_Sym *, const char *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *)'} to 'int (*)(void *, const GElf_Sym *, const char *, const prsyminfo_t *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *, const struct prsyminfo *)'} [-Werror=cast-function-type] PRO_NATURAL, (proc_xsym_f *)func, cd)); ^ ../common/Psymtab.c: In function 'Psymbol_iter_by_addr': ../common/Psymtab.c:2928:18: error: cast between incompatible function types from 'int (*)(void *, const GElf_Sym *, const char *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *)'} to 'int (*)(void *, const GElf_Sym *, const char *, const prsyminfo_t *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *, const struct prsyminfo *)'} [-Werror=cast-function-type] PRO_BYADDR, (proc_xsym_f *)func, cd)); ^ ../common/Psymtab.c: In function 'Psymbol_iter_by_name': ../common/Psymtab.c:2936:18: error: cast between incompatible function types from 'int (*)(void *, const GElf_Sym *, const char *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *)'} to 'int (*)(void *, const GElf_Sym *, const char *, const prsyminfo_t *)' {aka 'int (*)(void *, const struct <anonymous> *, const char *, const struct prsyminfo *)'} [-Werror=cast-function-type] PRO_BYNAME, (proc_xsym_f *)func, cd)); ^ cc1: all warnings being treated as errors
Updated by Electric Monk over 2 years ago
- Status changed from In Progress to Closed
- % Done changed from 90 to 100
git commit 78d83021c1426eb570f801cac4175645da13efe4
commit 78d83021c1426eb570f801cac4175645da13efe4 Author: Toomas Soome <tsoome@me.com> Date: 2019-11-20T23:08:25.000Z 11986 libproc: cast between incompatible function types Reviewed by: John Levon <john.levon@joyent.com> Approved by: Dan McDonald <danmcd@joyent.com>
Actions