ReactOS  0.4.15-dev-5496-g599ba9c
ioapi.c File Reference
#include "ioapi.h"
Include dependency graph for ioapi.c:

Go to the source code of this file.

Macros

#define FOPEN_FUNC(filename, mode)   fopen64(filename, mode)
 
#define FTELLO_FUNC(stream)   ftello64(stream)
 
#define FSEEKO_FUNC(stream, offset, origin)   fseeko64(stream, offset, origin)
 

Functions

voidpf call_zopen64 (const zlib_filefunc64_32_def *pfilefunc, const void *filename, int mode)
 
long call_zseek64 (const zlib_filefunc64_32_def *pfilefunc, voidpf filestream, ZPOS64_T offset, int origin)
 
ZPOS64_T call_ztell64 (const zlib_filefunc64_32_def *pfilefunc, voidpf filestream)
 
void fill_zlib_filefunc64_32_def_from_filefunc32 (zlib_filefunc64_32_def *p_filefunc64_32, const zlib_filefunc_def *p_filefunc32)
 
static voidpf ZCALLBACK fopen_file_func OF ((voidpf opaque, const char *filename, int mode))
 
static uLong ZCALLBACK fread_file_func OF ((voidpf opaque, voidpf stream, void *buf, uLong size))
 
static uLong ZCALLBACK fwrite_file_func OF ((voidpf opaque, voidpf stream, const void *buf, uLong size))
 
static ZPOS64_T ZCALLBACK ftell64_file_func OF ((voidpf opaque, voidpf stream))
 
static long ZCALLBACK fseek64_file_func OF ((voidpf opaque, voidpf stream, ZPOS64_T offset, int origin))
 
static voidpf ZCALLBACK fopen_file_func (voidpf opaque, const char *filename, int mode)
 
static voidpf ZCALLBACK fopen64_file_func (voidpf opaque, const void *filename, int mode)
 
static uLong ZCALLBACK fread_file_func (voidpf opaque, voidpf stream, void *buf, uLong size)
 
static uLong ZCALLBACK fwrite_file_func (voidpf opaque, voidpf stream, const void *buf, uLong size)
 
static long ZCALLBACK ftell_file_func (voidpf opaque, voidpf stream)
 
static ZPOS64_T ZCALLBACK ftell64_file_func (voidpf opaque, voidpf stream)
 
static long ZCALLBACK fseek_file_func (voidpf opaque, voidpf stream, uLong offset, int origin)
 
static long ZCALLBACK fseek64_file_func (voidpf opaque, voidpf stream, ZPOS64_T offset, int origin)
 
static int ZCALLBACK fclose_file_func (voidpf opaque, voidpf stream)
 
static int ZCALLBACK ferror_file_func (voidpf opaque, voidpf stream)
 
void fill_fopen_filefunc (zlib_filefunc_def *pzlib_filefunc_def)
 
void fill_fopen64_filefunc (zlib_filefunc64_def *pzlib_filefunc_def)
 

Macro Definition Documentation

◆ FOPEN_FUNC

#define FOPEN_FUNC (   filename,
  mode 
)    fopen64(filename, mode)

Definition at line 23 of file ioapi.c.

◆ FSEEKO_FUNC

#define FSEEKO_FUNC (   stream,
  offset,
  origin 
)    fseeko64(stream, offset, origin)

Definition at line 25 of file ioapi.c.

◆ FTELLO_FUNC

#define FTELLO_FUNC (   stream)    ftello64(stream)

Definition at line 24 of file ioapi.c.

Function Documentation

◆ call_zopen64()

voidpf call_zopen64 ( const zlib_filefunc64_32_def pfilefunc,
const void filename,
int  mode 
)

Definition at line 31 of file ioapi.c.

32 {
33  if (pfilefunc->zfile_func64.zopen64_file != NULL)
34  return (*(pfilefunc->zfile_func64.zopen64_file)) (pfilefunc->zfile_func64.opaque,filename,mode);
35  else
36  {
37  return (*(pfilefunc->zopen32_file))(pfilefunc->zfile_func64.opaque,(const char*)filename,mode);
38  }
39 }
open_file_func zopen32_file
Definition: ioapi.h:183
const char * filename
Definition: ioapi.h:137
zlib_filefunc64_def zfile_func64
Definition: ioapi.h:182
GLenum mode
Definition: glext.h:6217
#define NULL
Definition: types.h:112
open64_file_func zopen64_file
Definition: ioapi.h:166

◆ call_zseek64()

long call_zseek64 ( const zlib_filefunc64_32_def pfilefunc,
voidpf  filestream,
ZPOS64_T  offset,
int  origin 
)

Definition at line 41 of file ioapi.c.

42 {
43  if (pfilefunc->zfile_func64.zseek64_file != NULL)
44  return (*(pfilefunc->zfile_func64.zseek64_file)) (pfilefunc->zfile_func64.opaque,filestream,offset,origin);
45  else
46  {
47  uLong offsetTruncated = (uLong)offset;
48  if (offsetTruncated != offset)
49  return -1;
50  else
51  return (*(pfilefunc->zseek32_file))(pfilefunc->zfile_func64.opaque,filestream,offsetTruncated,origin);
52  }
53 }
voidpf uLong int origin
Definition: ioapi.h:144
unsigned long uLong
Definition: zlib.h:39
seek_file_func zseek32_file
Definition: ioapi.h:185
GLintptr offset
Definition: glext.h:5920
zlib_filefunc64_def zfile_func64
Definition: ioapi.h:182
#define NULL
Definition: types.h:112
seek64_file_func zseek64_file
Definition: ioapi.h:170

◆ call_ztell64()

ZPOS64_T call_ztell64 ( const zlib_filefunc64_32_def pfilefunc,
voidpf  filestream 
)

Definition at line 55 of file ioapi.c.

56 {
57  if (pfilefunc->zfile_func64.zseek64_file != NULL)
58  return (*(pfilefunc->zfile_func64.ztell64_file)) (pfilefunc->zfile_func64.opaque,filestream);
59  else
60  {
61  uLong tell_uLong = (uLong)(*(pfilefunc->ztell32_file))(pfilefunc->zfile_func64.opaque,filestream);
62  if ((tell_uLong) == MAXU32)
63  return (ZPOS64_T)-1;
64  else
65  return tell_uLong;
66  }
67 }
unsigned long uLong
Definition: zlib.h:39
zlib_filefunc64_def zfile_func64
Definition: ioapi.h:182
unsigned long long int ZPOS64_T
Definition: ioapi.h:99
tell_file_func ztell32_file
Definition: ioapi.h:184
#define NULL
Definition: types.h:112
#define MAXU32
Definition: ioapi.h:106
seek64_file_func zseek64_file
Definition: ioapi.h:170
tell64_file_func ztell64_file
Definition: ioapi.h:169

◆ fclose_file_func()

static int ZCALLBACK fclose_file_func ( voidpf  opaque,
voidpf  stream 
)
static

Definition at line 219 of file ioapi.c.

220 {
221  (void)opaque;
222  int ret;
223  ret = fclose((FILE *)stream);
224  return ret;
225 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
int ret
Definition: parse.h:22
_Check_return_opt_ _CRTIMP int __cdecl fclose(_Inout_ FILE *_File)

Referenced by fill_fopen64_filefunc(), and fill_fopen_filefunc().

◆ ferror_file_func()

static int ZCALLBACK ferror_file_func ( voidpf  opaque,
voidpf  stream 
)
static

Definition at line 227 of file ioapi.c.

228 {
229  (void)opaque;
230  int ret;
231  ret = ferror((FILE *)stream);
232  return ret;
233 }
_Check_return_ _CRTIMP int __cdecl ferror(_In_ FILE *_File)
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
int ret
Definition: parse.h:22

Referenced by fill_fopen64_filefunc(), and fill_fopen_filefunc().

◆ fill_fopen64_filefunc()

void fill_fopen64_filefunc ( zlib_filefunc64_def pzlib_filefunc_def)

Definition at line 248 of file ioapi.c.

249 {
250  pzlib_filefunc_def->zopen64_file = fopen64_file_func;
251  pzlib_filefunc_def->zread_file = fread_file_func;
252  pzlib_filefunc_def->zwrite_file = fwrite_file_func;
253  pzlib_filefunc_def->ztell64_file = ftell64_file_func;
254  pzlib_filefunc_def->zseek64_file = fseek64_file_func;
255  pzlib_filefunc_def->zclose_file = fclose_file_func;
256  pzlib_filefunc_def->zerror_file = ferror_file_func;
257  pzlib_filefunc_def->opaque = NULL;
258 }
testerror_file_func zerror_file
Definition: ioapi.h:172
static int ZCALLBACK fclose_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:219
static long ZCALLBACK fseek64_file_func(voidpf opaque, voidpf stream, ZPOS64_T offset, int origin)
Definition: ioapi.c:192
static ZPOS64_T ZCALLBACK ftell64_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:160
write_file_func zwrite_file
Definition: ioapi.h:168
close_file_func zclose_file
Definition: ioapi.h:171
static int ZCALLBACK ferror_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:227
read_file_func zread_file
Definition: ioapi.h:167
#define NULL
Definition: types.h:112
open64_file_func zopen64_file
Definition: ioapi.h:166
seek64_file_func zseek64_file
Definition: ioapi.h:170
static voidpf ZCALLBACK fopen64_file_func(voidpf opaque, const void *filename, int mode)
Definition: ioapi.c:115
static uLong ZCALLBACK fwrite_file_func(voidpf opaque, voidpf stream, const void *buf, uLong size)
Definition: ioapi.c:143
static uLong ZCALLBACK fread_file_func(voidpf opaque, voidpf stream, void *buf, uLong size)
Definition: ioapi.c:135
tell64_file_func ztell64_file
Definition: ioapi.h:169

Referenced by unzOpenInternal(), and zipOpen3().

◆ fill_fopen_filefunc()

void fill_fopen_filefunc ( zlib_filefunc_def pzlib_filefunc_def)

Definition at line 235 of file ioapi.c.

237 {
238  pzlib_filefunc_def->zopen_file = fopen_file_func;
239  pzlib_filefunc_def->zread_file = fread_file_func;
240  pzlib_filefunc_def->zwrite_file = fwrite_file_func;
241  pzlib_filefunc_def->ztell_file = ftell_file_func;
242  pzlib_filefunc_def->zseek_file = fseek_file_func;
243  pzlib_filefunc_def->zclose_file = fclose_file_func;
244  pzlib_filefunc_def->zerror_file = ferror_file_func;
245  pzlib_filefunc_def->opaque = NULL;
246 }
static long ZCALLBACK ftell_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:151
testerror_file_func zerror_file
Definition: ioapi.h:156
static int ZCALLBACK fclose_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:219
write_file_func zwrite_file
Definition: ioapi.h:152
read_file_func zread_file
Definition: ioapi.h:151
seek_file_func zseek_file
Definition: ioapi.h:154
tell_file_func ztell_file
Definition: ioapi.h:153
close_file_func zclose_file
Definition: ioapi.h:155
static int ZCALLBACK ferror_file_func(voidpf opaque, voidpf stream)
Definition: ioapi.c:227
open_file_func zopen_file
Definition: ioapi.h:150
#define NULL
Definition: types.h:112
static voidpf ZCALLBACK fopen_file_func(voidpf opaque, const char *filename, int mode)
Definition: ioapi.c:96
static long ZCALLBACK fseek_file_func(voidpf opaque, voidpf stream, uLong offset, int origin)
Definition: ioapi.c:168
static uLong ZCALLBACK fwrite_file_func(voidpf opaque, voidpf stream, const void *buf, uLong size)
Definition: ioapi.c:143
static uLong ZCALLBACK fread_file_func(voidpf opaque, voidpf stream, void *buf, uLong size)
Definition: ioapi.c:135

◆ fill_zlib_filefunc64_32_def_from_filefunc32()

void fill_zlib_filefunc64_32_def_from_filefunc32 ( zlib_filefunc64_32_def p_filefunc64_32,
const zlib_filefunc_def p_filefunc32 
)

Definition at line 70 of file ioapi.c.

71 {
72  p_filefunc64_32->zfile_func64.zopen64_file = NULL;
73  p_filefunc64_32->zopen32_file = p_filefunc32->zopen_file;
74  p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file;
75  p_filefunc64_32->zfile_func64.zread_file = p_filefunc32->zread_file;
76  p_filefunc64_32->zfile_func64.zwrite_file = p_filefunc32->zwrite_file;
77  p_filefunc64_32->zfile_func64.ztell64_file = NULL;
78  p_filefunc64_32->zfile_func64.zseek64_file = NULL;
79  p_filefunc64_32->zfile_func64.zclose_file = p_filefunc32->zclose_file;
80  p_filefunc64_32->zfile_func64.zerror_file = p_filefunc32->zerror_file;
81  p_filefunc64_32->zfile_func64.opaque = p_filefunc32->opaque;
82  p_filefunc64_32->zseek32_file = p_filefunc32->zseek_file;
83  p_filefunc64_32->ztell32_file = p_filefunc32->ztell_file;
84 }
open_file_func zopen32_file
Definition: ioapi.h:183
testerror_file_func zerror_file
Definition: ioapi.h:172
testerror_file_func zerror_file
Definition: ioapi.h:156
write_file_func zwrite_file
Definition: ioapi.h:152
write_file_func zwrite_file
Definition: ioapi.h:168
seek_file_func zseek32_file
Definition: ioapi.h:185
close_file_func zclose_file
Definition: ioapi.h:171
read_file_func zread_file
Definition: ioapi.h:151
seek_file_func zseek_file
Definition: ioapi.h:154
zlib_filefunc64_def zfile_func64
Definition: ioapi.h:182
tell_file_func ztell_file
Definition: ioapi.h:153
close_file_func zclose_file
Definition: ioapi.h:155
tell_file_func ztell32_file
Definition: ioapi.h:184
open_file_func zopen_file
Definition: ioapi.h:150
read_file_func zread_file
Definition: ioapi.h:167
#define NULL
Definition: types.h:112
open64_file_func zopen64_file
Definition: ioapi.h:166
seek64_file_func zseek64_file
Definition: ioapi.h:170
tell64_file_func ztell64_file
Definition: ioapi.h:169

Referenced by unzOpen2(), and zipOpen2().

◆ fopen64_file_func()

static voidpf ZCALLBACK fopen64_file_func ( voidpf  opaque,
const void filename,
int  mode 
)
static

Definition at line 115 of file ioapi.c.

116 {
117  (void)opaque;
118  FILE* file = NULL;
119  const char* mode_fopen = NULL;
121  mode_fopen = "rb";
122  else
124  mode_fopen = "r+b";
125  else
127  mode_fopen = "wb";
128 
129  if ((filename!=NULL) && (mode_fopen != NULL))
130  file = FOPEN_FUNC((const char*)filename, mode_fopen);
131  return file;
132 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
#define ZLIB_FILEFUNC_MODE_READWRITEFILTER
Definition: ioapi.h:120
#define ZLIB_FILEFUNC_MODE_READ
Definition: ioapi.h:118
const char * filename
Definition: ioapi.h:137
const char file[]
Definition: icontest.c:11
#define ZLIB_FILEFUNC_MODE_CREATE
Definition: ioapi.h:123
#define ZLIB_FILEFUNC_MODE_EXISTING
Definition: ioapi.h:122
GLenum mode
Definition: glext.h:6217
#define NULL
Definition: types.h:112
#define FOPEN_FUNC(filename, mode)
Definition: ioapi.c:23
Definition: fci.c:126

Referenced by fill_fopen64_filefunc().

◆ fopen_file_func()

static voidpf ZCALLBACK fopen_file_func ( voidpf  opaque,
const char filename,
int  mode 
)
static

Definition at line 96 of file ioapi.c.

97 {
98  (void)opaque;
99  FILE* file = NULL;
100  const char* mode_fopen = NULL;
102  mode_fopen = "rb";
103  else
105  mode_fopen = "r+b";
106  else
108  mode_fopen = "wb";
109 
110  if ((filename!=NULL) && (mode_fopen != NULL))
111  file = fopen(filename, mode_fopen);
112  return file;
113 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
#define ZLIB_FILEFUNC_MODE_READWRITEFILTER
Definition: ioapi.h:120
#define ZLIB_FILEFUNC_MODE_READ
Definition: ioapi.h:118
const char * filename
Definition: ioapi.h:137
const char file[]
Definition: icontest.c:11
#define ZLIB_FILEFUNC_MODE_CREATE
Definition: ioapi.h:123
#define ZLIB_FILEFUNC_MODE_EXISTING
Definition: ioapi.h:122
_Check_return_ _CRTIMP FILE *__cdecl fopen(_In_z_ const char *_Filename, _In_z_ const char *_Mode)
GLenum mode
Definition: glext.h:6217
#define NULL
Definition: types.h:112
Definition: fci.c:126

Referenced by fill_fopen_filefunc().

◆ fread_file_func()

static uLong ZCALLBACK fread_file_func ( voidpf  opaque,
voidpf  stream,
void buf,
uLong  size 
)
static

Definition at line 135 of file ioapi.c.

136 {
137  (void)opaque;
138  uLong ret;
139  ret = (uLong)fread(buf, 1, (size_t)size, (FILE *)stream);
140  return ret;
141 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
unsigned long uLong
Definition: zlib.h:39
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
_Check_return_opt_ _CRTIMP size_t __cdecl fread(_Out_writes_bytes_(_ElementSize *_Count) void *_DstBuf, _In_ size_t _ElementSize, _In_ size_t _Count, _Inout_ FILE *_File)
GLsizeiptr size
Definition: glext.h:5919
int ret
Definition: parse.h:22

Referenced by fill_fopen64_filefunc(), and fill_fopen_filefunc().

◆ fseek64_file_func()

static long ZCALLBACK fseek64_file_func ( voidpf  opaque,
voidpf  stream,
ZPOS64_T  offset,
int  origin 
)
static

Definition at line 192 of file ioapi.c.

193 {
194  (void)opaque;
195  int fseek_origin=0;
196  long ret;
197  switch (origin)
198  {
200  fseek_origin = SEEK_CUR;
201  break;
203  fseek_origin = SEEK_END;
204  break;
206  fseek_origin = SEEK_SET;
207  break;
208  default: return -1;
209  }
210  ret = 0;
211 
212  if(FSEEKO_FUNC((FILE *)stream, (long)offset, fseek_origin) != 0)
213  ret = -1;
214 
215  return ret;
216 }
#define SEEK_CUR
Definition: util.h:63
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
voidpf uLong int origin
Definition: ioapi.h:144
#define ZLIB_FILEFUNC_SEEK_CUR
Definition: ioapi.h:114
#define SEEK_SET
Definition: jmemansi.c:26
GLintptr offset
Definition: glext.h:5920
int ret
Definition: parse.h:22
#define ZLIB_FILEFUNC_SEEK_END
Definition: ioapi.h:115
#define FSEEKO_FUNC(stream, offset, origin)
Definition: ioapi.c:25
#define SEEK_END
Definition: cabinet.c:27
#define ZLIB_FILEFUNC_SEEK_SET
Definition: ioapi.h:116

Referenced by fill_fopen64_filefunc().

◆ fseek_file_func()

static long ZCALLBACK fseek_file_func ( voidpf  opaque,
voidpf  stream,
uLong  offset,
int  origin 
)
static

Definition at line 168 of file ioapi.c.

169 {
170  (void)opaque;
171  int fseek_origin=0;
172  long ret;
173  switch (origin)
174  {
176  fseek_origin = SEEK_CUR;
177  break;
179  fseek_origin = SEEK_END;
180  break;
182  fseek_origin = SEEK_SET;
183  break;
184  default: return -1;
185  }
186  ret = 0;
187  if (fseek((FILE *)stream, (long)offset, fseek_origin) != 0)
188  ret = -1;
189  return ret;
190 }
#define SEEK_CUR
Definition: util.h:63
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
voidpf uLong int origin
Definition: ioapi.h:144
#define ZLIB_FILEFUNC_SEEK_CUR
Definition: ioapi.h:114
_Check_return_opt_ _CRTIMP int __cdecl fseek(_Inout_ FILE *_File, _In_ long _Offset, _In_ int _Origin)
#define SEEK_SET
Definition: jmemansi.c:26
GLintptr offset
Definition: glext.h:5920
int ret
Definition: parse.h:22
#define ZLIB_FILEFUNC_SEEK_END
Definition: ioapi.h:115
#define SEEK_END
Definition: cabinet.c:27
#define ZLIB_FILEFUNC_SEEK_SET
Definition: ioapi.h:116

Referenced by fill_fopen_filefunc().

◆ ftell64_file_func()

static ZPOS64_T ZCALLBACK ftell64_file_func ( voidpf  opaque,
voidpf  stream 
)
static

Definition at line 160 of file ioapi.c.

161 {
162  (void)opaque;
163  ZPOS64_T ret;
165  return ret;
166 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
unsigned long long int ZPOS64_T
Definition: ioapi.h:99
#define FTELLO_FUNC(stream)
Definition: ioapi.c:24
int ret
GLuint GLuint stream
Definition: glext.h:7522

Referenced by fill_fopen64_filefunc().

◆ ftell_file_func()

static long ZCALLBACK ftell_file_func ( voidpf  opaque,
voidpf  stream 
)
static

Definition at line 151 of file ioapi.c.

152 {
153  (void)opaque;
154  long ret;
155  ret = ftell((FILE *)stream);
156  return ret;
157 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
int ret
Definition: parse.h:22
_Check_return_ _CRTIMP long __cdecl ftell(_Inout_ FILE *_File)

Referenced by fill_fopen_filefunc().

◆ fwrite_file_func()

static uLong ZCALLBACK fwrite_file_func ( voidpf  opaque,
voidpf  stream,
const void buf,
uLong  size 
)
static

Definition at line 143 of file ioapi.c.

144 {
145  (void)opaque;
146  uLong ret;
147  ret = (uLong)fwrite(buf, 1, (size_t)size, (FILE *)stream);
148  return ret;
149 }
struct png_info_def **typedef void(__cdecl typeof(png_destroy_read_struct))(struct png_struct_def **
Definition: typeof.h:49
_Check_return_opt_ _CRTIMP size_t __cdecl fwrite(_In_reads_bytes_(_Size *_Count) const void *_Str, _In_ size_t _Size, _In_ size_t _Count, _Inout_ FILE *_File)
unsigned long uLong
Definition: zlib.h:39
GLenum GLuint GLenum GLsizei const GLchar * buf
Definition: glext.h:7751
GLsizeiptr size
Definition: glext.h:5919
int ret
Definition: parse.h:22

Referenced by fill_fopen64_filefunc(), and fill_fopen_filefunc().

◆ OF() [1/5]

static voidpf ZCALLBACK fopen_file_func OF ( (voidpf opaque, const char *filename, int mode )
static

◆ OF() [2/5]

static uLong ZCALLBACK fread_file_func OF ( (voidpf opaque, voidpf stream, void *buf, uLong size )
static

◆ OF() [3/5]

static uLong ZCALLBACK fwrite_file_func OF ( (voidpf opaque, voidpf stream, const void *buf, uLong size )
static

◆ OF() [4/5]

static ZPOS64_T ZCALLBACK ftell64_file_func OF ( (voidpf opaque, voidpf stream )
static

◆ OF() [5/5]