RE: [Dev-C++] (bug) passing a filename to a console program is broken
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Ioannis V. <no...@ya...> - 2000-11-21 04:38:09
|
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...]On Behalf Of
> Alexei Podetlezhnikov
> Sent: Thursday, November 16, 2000 4:30 AM
> To: dev...@li...
> Subject: [Dev-C++] (bug) passing a filename to a console program is broken
>
>
> Passing a file name to a console program as a parameter requires full
> path to work by clicking "Run" under IDE. Without full path the
> executable is not able to locate and open the file. Normally, the
> executable should find the file in the working directory. This means
> that the environment option to "execute in directory of executable" is
> not working even if checked. In fact, the executable runs in
> c:\dev-c++\bin\ directory, I suspect.
>
> To observe the behavior
> 1) run devcpp.exe from program menu.
> 2) compile this program:
>
> #include<stdio.h>
>
> main(int argc, char** argv)
> {
> FILE *f;
>
> if ( argc > 1 )
> {
> f=fopen(argv[1],"rt");
rt is invalid mode. You probably mean r+?
Ioannis
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com
|