10188 libast: cast between incompatible function types
Review Request #1348 — Created Jan. 9, 2019 and submitted
Information | |
---|---|
tsoome | |
illumos-gate | |
10188 | |
50c5c72... | |
Reviewers | |
general | |
../common/misc/mime.c: In function 'mimehead': ../common/misc/mime.c:744:37: error: cast between incompatible function types from 'int (*)(const char *, const char *, char **)' to 'int (*)(const char *, const char *)' [-Werror=cast-function-type] if ((p = strsearch(tab, num, siz, (Strcmp_f)mimecmp, s, &e)) && *e == ':') ^ ../common/misc/mime.c:753:40: error: cast between incompatible function types from 'int (*)(const char *, const char *, char **)' to 'int (*)(const char *, const char *)' [-Werror=cast-function-type] (p = strsearch(tab, num, siz, (Strcmp_f)mimecmp, pp.name.data, &e)) && ^ ../common/misc/glob.c: In function '_ast_glob': ../common/misc/glob.c:630:22: error: cast between incompatible function types from 'int (*)(DIR *)' {aka 'int (*)(struct <anonymous> *)'} to 'void (*)(void *)' [-Werror=cast-function-type] gp->gl_closedir = (GL_closedir_f)closedir; ^ ../common/string/strsearch.c: In function '_ast_strsearch': ../common/string/strsearch.c:50:25: error: cast between incompatible function types from 'Strcmp_f' {aka 'int (*)(const char *, const char *)'} to 'int (*)(const char *, const char *, void *)' [-Werror=cast-function-type] if (!(v = context ? (*(Strcmp_context_f)comparf)(name, *((char**)mid), context) : (*comparf)(name, *((char**)mid)))) ^ cc1: all warnings being treated as errors