FIX: C1024 or C1083 Error When INCLUDE Set to Root Directory (97809)
The information in this article applies to:
- Microsoft C/C++ for MS-DOS 7.0
- Microsoft Visual C++ for Windows, 16-bit edition 1.0
- Microsoft Visual C++ for Windows, 16-bit edition 1.5
- Microsoft Visual C++, 32-bit Editions 1.0
This article was previously published under Q97809 SYMPTOMS
An attempt to compile an application fails and Microsoft C/C++
generates one of the following messages. For version 8.0:
fatal error C1083: Cannot open include file: 'stdio.h':
Permission denied
For version 7.0:
fatal error C1024: cannot open include file 'stdio.h'
The application compiles correctly in Microsoft C version 6.0 for
MS-DOS.
CAUSE
The INCLUDE environment variable specifies the root directory of a
drive and a required header file is located in the root directory.
This occurs most often when the MS-DOS SUBST command creates a
drive letter for a subdirectory on a drive.
RESOLUTION
To work around this problem, edit your AUTOEXEC.BAT file to replace
the backslash character (\) in the directory specification with a
forward slash character (/). For example, the modified SET
statement would appear as follows:
set INCLUDE=C:/
For a drive letter created with the SUBST command, omitting the
backslash character entirely also works. For example:
set INCLUDE=M:
STATUS
Microsoft has confirmed this to be a bug in the products listed at the
beginning of this article. This bug was corrected in C/C++ version 9.0,
included with Visual C++ 32-bit Edition, version 2.0.
Modification Type: | Minor | Last Reviewed: | 7/5/2005 |
---|
Keywords: | kbbug kbCompiler kbfix KB97809 |
---|
|