File and Path Function
int stat64(const char *path, struct __stat64 *buffer);
int _stat64(const char *path, struct __stat64 *buffer);
int _wstat64(const wchar_t *path, struct __stat64 *buffer);
int _tstat64(const TCHAR *path, struct __stat64 *buffer);
Internationalization (I18n) Function Overview
The stat64 function retrieves file or directory information for path and stores it in buffer .
The function returns 0 if successful; otherwise, it returns -1
and sets the global errno variable to ENOENT , indicating that the filename or path could not be found.
This function is similar to stat , but it is also able to
work on files larger then 2^31 bytes on 32-bit systems. To be able to do this,
the result is stored in a variable of type struct stat64 , which is the data type that
the buffer argument points to.
_stat64 is the same as stat64 , supported on Windows platforms.
It automatically handles multibyte-character string arguments as appropriate, recognizing multibyte-character
sequences according to the multibyte code page currently in use.
Also, on Windows platforms, _wstat64 is the wide-character version of _stat64 ;
its argument is a wide-character string. There is no ANSI wide-character equivalent.
_tstat64 is the Windows-only Generic version of the function; with the
_MBCS or _UNICODE compiler flags determining its mapping to either
_stat64 or _wstat64 .
I18n Issues
Use the appropriate version of the function as required for internationalization support.
The Windows _stat64 function depends on the multibyte code page in effect. By default, the multibyte code page
is set to the system-default ANSI code page obtained from the operating system at program startup.
Use _getmbcp and _setmbcp to query or change
the current multibyte code page, respectively.
On ANSI UTF-16 platforms, use a conversion function to convert the
wide-character string to a multibyte-character string and then call stat64 .
See Pathnames for a discussion of path and filename considerations in
an internationalized application.
Recommended Replacements*
*If you're already using the recommended function, see I18n Issues for other reasons why Globalyzer is detecting the function.
File and Path Functions
|