kmod/tools
Lucas De Marchi 22c36b7dac depmod: Fix warning with -D_TIME_BITS=64
Printing time_t, suseconds_t, useconds_t in 32bits with -D_TIME_BITS=64
leads to the following warning:

../tools/depmod.c:2641:61: warning: format ‘%li’ expects argument of type ‘long int’, but argument 6 has type ‘__suseconds64_t’ {aka ‘long long int’} [-Wformat=]
 2641 |                         snprintf(tmp, sizeof(tmp), "%s.%i.%li.%li", itr->name, getpid(),
      |                                                           ~~^
      |                                                             |
      |                                                             long int
      |                                                           %lli
 2642 |                                         tv.tv_usec, tv.tv_sec);
      |                                         ~~~~~~~~~~

Paper it over by casting the argument to 64 bits and switching to long long.

Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
2024-06-11 08:15:30 -05:00
..
.gitignore tools: Use test/kmod instead of kmod-nolib 2013-07-02 21:15:54 -03:00
COPYING Clarify what licences apply where 2014-10-09 01:26:34 -03:00
depmod.c depmod: Fix warning with -D_TIME_BITS=64 2024-06-11 08:15:30 -05:00
insmod.c insmod: fix wron fallthrough of -f 2015-11-20 19:26:33 -02:00
kmod.c Use portable implementation for basename API 2024-06-10 18:15:39 -05:00
kmod.h tools: add basic versions of insert and remove 2015-03-07 12:09:51 -03:00
kmod.pc.in libkmod, depmod, modprobe: Make directory for kernel modules configurable 2023-12-06 09:53:05 -06:00
log.c Change default log level 2015-09-30 15:17:01 -03:00
log.h Add format attribute and fix issues 2013-04-21 16:17:12 -03:00
lsmod.c Fix spurious spaces in lsmod output 2015-04-16 08:46:43 -03:00
Makefile build-sys: add small redirecting Makefiles 2014-03-06 01:59:58 -03:00
modinfo.c libkmod, depmod, modprobe: Make directory for kernel modules configurable 2023-12-06 09:53:05 -06:00
modprobe.c libkmod: add weak dependecies 2024-05-08 23:37:38 -05:00
rmmod.c tools: Print a message if refcnt attribute is missing 2019-03-08 13:06:52 -08:00
static-nodes.c libkmod, depmod, modprobe: Make directory for kernel modules configurable 2023-12-06 09:53:05 -06:00