Page MenuHomeFreeBSD

rtld-elf: make it compile with WARNS=3
ClosedPublic

Authored by arichardson on Sep 13 2018, 1:50 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Mar 7, 2:45 PM
Unknown Object (File)
Thu, Mar 6, 6:48 PM
Unknown Object (File)
Fri, Feb 28, 9:15 PM
Unknown Object (File)
Jan 25 2025, 7:44 PM
Unknown Object (File)
Jan 18 2025, 5:55 PM
Unknown Object (File)
Jan 17 2025, 5:55 PM
Unknown Object (File)
Jan 3 2025, 3:12 PM
Unknown Object (File)
Dec 27 2024, 8:54 PM
Subscribers

Diff Detail

Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 19570
Build 19155: arc lint + arc unit

Event Timeline

libexec/rtld-elf/libmap.c
202

Merge 'i' declaration with the 'cnt' line.

libexec/rtld-elf/malloc.c
160–163

Use the opportunity to remove 'register' qualifier ?

libexec/rtld-elf/rtld.c
271

Wny this type change is needed ?

libexec/rtld-elf/malloc.c
160–163

Okay, will do.

libexec/rtld-elf/rtld.c
271

signed-unsigned comparison. I could also add a cast instead?

libexec/rtld-elf/rtld.c
271

I think that new type for the var should be Elf_Addr, if any. Look at its use. In fact this is an ABI issue.

Practically Elf_Addr has the same representation as size_t on all supported platforms, but this is not strictly required.

arichardson marked 6 inline comments as done.
  • Address feedback
  • remove register specifier from malloc.c
kib added inline comments.
libexec/rtld-elf/libmap.h
8

I would do a follow-up commit removing space before '('. Or you might add it to this change.

This revision is now accepted and ready to land.Sep 13 2018, 3:39 PM

I'd mention the de-register part of the change in the commit message as well as the warns fixes.

This revision was automatically updated to reflect the committed changes.