1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 09:34:59 +00:00

Userland: Fix 64-bit portability issues

This commit is contained in:
Gunnar Beutner 2021-05-02 00:00:52 +02:00 committed by Andreas Kling
parent fdbe66a7b4
commit b613817bca
15 changed files with 59 additions and 30 deletions

View file

@ -9,6 +9,7 @@
#include <LibCore/ArgsParser.h>
#include <LibCore/DateTime.h>
#include <grp.h>
#include <inttypes.h>
#include <pwd.h>
#include <stdio.h>
#include <sys/stat.h>
@ -28,7 +29,7 @@ static int stat(const char* file, bool should_follow_links)
if (S_ISCHR(st.st_mode) || S_ISBLK(st.st_mode))
printf(" Device: %u,%u\n", major(st.st_rdev), minor(st.st_rdev));
else
printf(" Size: %lld\n", st.st_size);
printf(" Size: %" PRIi64 "\n", st.st_size);
printf(" Links: %u\n", st.st_nlink);
printf(" Blocks: %u\n", st.st_blocks);
printf(" UID: %u", st.st_uid);