* [LTP] [PATCH] lapi/ustat.h: Replace daddr_t with long
@ 2019-05-20 21:49 Petr Vorel
2019-05-21 14:01 ` Cyril Hrubis
0 siblings, 1 reply; 2+ messages in thread
From: Petr Vorel @ 2019-05-20 21:49 UTC (permalink / raw)
To: ltp
From: Petr Vorel <petr.vorel@gmail.com>
daddr_t is usually typedef to __kernel_daddr_t,
which is int or long.
Using long as daddr_t is not defined at least on musl.
Signed-off-by: Petr Vorel <petr.vorel@gmail.com>
---
include/lapi/ustat.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/lapi/ustat.h b/include/lapi/ustat.h
index 12c073582..030179c4a 100644
--- a/include/lapi/ustat.h
+++ b/include/lapi/ustat.h
@@ -11,7 +11,7 @@
# include <sys/ustat.h>
#else
struct ustat {
- daddr_t f_tfree;
+ long f_tfree;
ino_t f_tinode;
char f_fname[6];
char f_fpack[6];
--
2.21.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [LTP] [PATCH] lapi/ustat.h: Replace daddr_t with long
2019-05-20 21:49 [LTP] [PATCH] lapi/ustat.h: Replace daddr_t with long Petr Vorel
@ 2019-05-21 14:01 ` Cyril Hrubis
0 siblings, 0 replies; 2+ messages in thread
From: Cyril Hrubis @ 2019-05-21 14:01 UTC (permalink / raw)
To: ltp
Hi!
> daddr_t is usually typedef to __kernel_daddr_t,
> which is int or long.
Well the size must match, so unless you have checked that it's defined
to int only in cases where sizeof(int) == sizeof(long) this change is
not correct.
--
Cyril Hrubis
chrubis@suse.cz
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-05-21 14:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-20 21:49 [LTP] [PATCH] lapi/ustat.h: Replace daddr_t with long Petr Vorel
2019-05-21 14:01 ` Cyril Hrubis
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox