INF: ;C_FILE_INFO Purpose in Child Process Environment
PSS ID Number: Q11867
Article last modified on 12-21-1993

3.00 4.00 5.00 5.10 6.00 6.00a 6.00ax | 5.10 6.00 6.00a

MS-DOS                                | OS/2


----------------------------------------------------------------------
The information in this article applies to:

 - Microsoft C for MS-DOS, versions 3.0, 4.0, 5.0, 5.1, 6.0, 6.0a, and
   6.0ax
 - Microsoft C for OS/2, versions 5.1, 6.0, and 6.0a
----------------------------------------------------------------------

SUMMARY
=======

When an application compiled in Microsoft C spawns a process, the
environment includes a ;C_FILE_INFO or _C_FILE_INFO variable.
(Versions of the run-time library earlier than version 5.1 uses the
;C_FILE_INFO variable and versions 5.1 and later use the _C_FILE_INFO
variable). Through the variable, the run-time library passes up to
twenty bytes of information about open files to the child process. The
start-up code in the spawned application reads the information from
the variable and removes the variable from the environment.

The run-time library implements the system() function by spawning
COMMAND.COM. Because COMMAND.COM does not use the C run-time library,
the ;C_FILE_INFO (or _C_FILE_INFO) variable remains in the
environment.

The name of this variable should prevent it from interfering with any
user-defined environment variable.

Additional reference words: 3.00 4.00 5.00 5.10 6.00 6.00a 6.00ax

=============================================================================

Copyright Microsoft Corporation 1993.
