Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 943694 - sys-process/lsof-4.99.3 fails to compile: lib/misc.c:369:26: error: too many arguments to function ‘r_fn’
Summary: sys-process/lsof-4.99.3 fails to compile: lib/misc.c:369:26: error: too many ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
: 943869 944271 (view as bug list)
Depends on:
Blocks: c23-porting
  Show dependency tree
 
Reported: 2024-11-17 19:23 UTC by Kostadin Shishmanov
Modified: 2024-11-21 13:03 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
build log (build.log,211.69 KB, text/x-log)
2024-11-17 19:23 UTC, Kostadin Shishmanov
Details
build log (build.log,24.37 KB, text/x-log)
2024-11-17 19:26 UTC, Kostadin Shishmanov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kostadin Shishmanov 2024-11-17 19:23:35 UTC
Created attachment 908891 [details]
build log

sys-process/lsof-4.99.3 fails to compile with gcc 15-9999, adding -std=gnu17 to CFLAGS makes it build.



lib/misc.c: In function ‘doinchild’:
lib/misc.c:369:26: error: too many arguments to function ‘r_fn’
  369 |                     rv = r_fn(r_arg, r.r_rbuf, r_rbln);
      |                          ^~~~
lib/misc.c:422:14: error: too many arguments to function ‘fn’
  422 |         rv = fn(fp, rbuf, rbln);
      |              ^~
lib/misc.c: In function ‘lstatsafely’:
lib/misc.c:998:28: error: passing argument 2 of ‘doinchild’ from incompatible pointer type [-Wincompatible-pointer-types]
  998 |     return (doinchild(ctx, dolstat, path, (char *)buf, sizeof(struct stat)));
      |                            ^~~~~~~
      |                            |
      |                            int (*)(char *, char *, int)
lib/misc.c:241:28: note: expected ‘int (*)(void)’ but argument is of type ‘int (*)(char *, char *, int)’
  241 |                      int (*fn)(), /* function to perform */
      |                      ~~~~~~^~~~~
lib/misc.c: In function ‘Readlink’:
lib/misc.c:1058:36: error: passing argument 2 of ‘doinchild’ from incompatible pointer type [-Wincompatible-pointer-types]
 1058 |         if ((llen = doinchild(ctx, doreadlink, tbuf, lbuf, sizeof(lbuf) - 1)) >=
      |                                    ^~~~~~~~~~
      |                                    |
      |                                    int (*)(char *, char *, int)
lib/misc.c:241:28: note: expected ‘int (*)(void)’ but argument is of type ‘int (*)(char *, char *, int)’
  241 |                      int (*fn)(), /* function to perform */
      |                      ~~~~~~^~~~~
lib/misc.c: In function ‘statsafely’:
lib/misc.c:1508:28: error: passing argument 2 of ‘doinchild’ from incompatible pointer type [-Wincompatible-pointer-types]
 1508 |     return (doinchild(ctx, dostat, path, (char *)buf, sizeof(struct stat)));
      |                            ^~~~~~
      |                            |
      |                            int (*)(char *, char *, int)
lib/misc.c:241:28: note: expected ‘int (*)(void)’ but argument is of type ‘int (*)(char *, char *, int)’
  241 |                      int (*fn)(), /* function to perform */
      |                      ~~~~~~^~~~~
Comment 1 Kostadin Shishmanov 2024-11-17 19:26:14 UTC
Created attachment 908892 [details]
build log

sorry, the previously attached log was for another bug.
Comment 2 Larry the Git Cow gentoo-dev 2024-11-18 12:29:10 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=78143eec123c0601b77631d989eba1ff030322fc

commit 78143eec123c0601b77631d989eba1ff030322fc
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2024-11-18 12:28:02 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-11-18 12:28:12 +0000

    sys-process/lsof: add 4.99.4
    
    Closes: https://bugs.gentoo.org/943694
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-process/lsof/Manifest           |  1 +
 sys-process/lsof/lsof-4.99.4.ebuild | 52 +++++++++++++++++++++++++++++++++++++
 2 files changed, 53 insertions(+)
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-11-19 04:44:24 UTC
*** Bug 943869 has been marked as a duplicate of this bug. ***
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-11-21 13:03:46 UTC
*** Bug 944271 has been marked as a duplicate of this bug. ***