delorie.com/djgpp/doc/libc/libc_622.html   search  
libc.a reference

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

_preserve_fncase

Syntax

 
#include <fcntl.h>

char _preserve_fncase (void);

Description

This function returns a non-zero value if letter-case in filenames should be preserved. It is used by library functions that get filenames from the operating system (like readdir, _fixpath and others). The usual behavior of these functions (when _preserve_fncase returns zero) is to down-case 8+3 DOS-style filenames, but leave alone the letter-case in long filenames when these are supported (see section _use_lfn). This can be changed by either setting _CRT0_FLAG_PRESERVE_FILENAME_CASE bit in the _crt0_startup_flags variable (see section _crt0_startup_flags), or by setting the FNCASE environment variable to Y at run time. You might need such a setup e.g. on Windows 95 if you want to see files with names like `README' and `FAQ' listed in upper-case (for this to work, you will have to manually rename all the other files with 8+3 DOS-style names to lower-case names). When the case in filenames is preserved, all filenames will be returned in upper case on MSDOS (and other systems that don't support long filenames), or if the environment variable LFN is set to N on systems that support LFN. That is because this is how filenames are stored in the DOS directory entries.

Return value

Zero when 8+3 filenames should be converted to lower-case, non-zero otherwise.

Portability

ANSI/ISO C No
POSIX No


  webmaster     delorie software   privacy  
  Copyright © 2004     Updated Apr 2004