malloc_get_state.3: tfix
[man-pages.git] / man3type / off_t.3type
blob4b3838917607afd2fc80a1479b67bd9b1cc66700
1 .\" Copyright (c) 2020-2022 by Alejandro Colomar <alx@kernel.org>
2 .\" and Copyright (c) 2020 by Michael Kerrisk <mtk.manpages@gmail.com>
3 .\"
4 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
5 .\"
6 .\"
7 .TH off_t 3type (date) "Linux man-pages (unreleased)"
8 .SH NAME
9 off_t, off64_t, loff_t \- file sizes
10 .SH LIBRARY
11 Standard C library
12 .RI ( libc )
13 .SH SYNOPSIS
14 .nf
15 .B #include <sys/types.h>
17 .BR typedef " /* ... */  " off_t;
19 .B #define _LARGEFILE64_SOURCE
20 .B #include <sys/types.h>
22 .BR typedef " /* ... */  " off64_t;
24 .B #define _GNU_SOURCE
25 .B #include <sys/types.h>
27 .BR typedef " /* ... */  " loff_t;
28 .fi
29 .SH DESCRIPTION
30 .I off_t
31 is used for describing file sizes.
32 It is a signed integer type.
34 .I off64_t
35 is a 64-bit version of the type,
36 used in glibc.
38 .I loff_t
39 is a 64-bit version of the type,
40 introduced by the Linux kernel.
41 .SH STANDARDS
42 .TP
43 .I off_t
44 POSIX.1-2008.
45 .TP
46 .I off64_t
47 GNU and some BSDs.
48 .TP
49 .I loff_t
50 Linux.
51 .SH VERSIONS
52 .TP
53 .I off_t
54 POSIX.1-2001.
56 .I <aio.h>
57 and
58 .I <stdio.h>
59 define
60 .I off_t
61 since POSIX.1-2008.
62 .SH NOTES
63 On some architectures,
64 the width of
65 .I off_t
66 can be controlled with the feature test macro
67 .BR _FILE_OFFSET_BITS .
69 The following headers also provide
70 .IR off_t :
71 .IR <aio.h> ,
72 .IR <fcntl.h> ,
73 .IR <stdio.h> ,
74 .IR <sys/mman.h> ,
75 .IR <sys/stat.h> ,
76 and
77 .IR <unistd.h> .
78 .SH SEE ALSO
79 .BR copy_file_range (2),
80 .BR llseek (2),
81 .BR lseek (2),
82 .BR mmap (2),
83 .BR posix_fadvise (2),
84 .BR pread (2),
85 .BR readahead (2),
86 .BR sync_file_range (2),
87 .BR truncate (2),
88 .BR fseeko (3),
89 .BR lockf (3),
90 .BR lseek64 (3),
91 .BR posix_fallocate (3),
92 .BR feature_test_macros (7)