From: Chandan Rajendra Date: Mon, 13 Nov 2017 14:45:26 +0000 (+0530) Subject: src/t_dir_type.c: Use strtoul() instead of atoll() X-Git-Tag: v2022.05.01~1782 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=9edb6cd35d13e3a6c66b2f8149867d1544a456c1;p=xfstests-dev.git src/t_dir_type.c: Use strtoul() instead of atoll() An overlayfs filesystem instance with one lowerdir filesystem and with "xino" mount option enabled can have the layer index encoded in the 63rd bit of the inode number. A signed 64 bit integer won't suffice to store this inode number. Hence this commit uses strtoul() to convert the inode number in string form to unsigned integer form. Signed-off-by: Chandan Rajendra Reviewed-by: Amir Goldstein Signed-off-by: Eryu Guan --- diff --git a/src/t_dir_type.c b/src/t_dir_type.c index 76aaa9bb..7bba3043 100644 --- a/src/t_dir_type.c +++ b/src/t_dir_type.c @@ -85,7 +85,7 @@ main(int argc, char *argv[]) break; /* no match ends up with type = -1 */ if (type < 0) - ino = atoll(argv[2]); + ino = strtoul(argv[2], NULL, 10); } for ( ; ; ) {