1. Printf fn=-1 and it still works
- Posted by Daniel Kluss <codepilot at gmail.com> Dec 17, 2005
- 513 views
- Last edited Dec 18, 2005
I have to say that I would expect an error, but that is just weird that it works. If you open a file for reading and you use printf it complains though. I'm using exw.exe if that makes a difference. Dan
2. Re: Printf fn=-1 and it still works
- Posted by Robert Craig <rds at RapidEuphoria.com> Dec 18, 2005
- 515 views
Daniel Kluss wrote: > I have to say that I would expect an error, but that is just weird that it > works. > If you open a file for reading and you use printf it complains though. > I'm using exw.exe if that makes a difference. That's a bug. Thanks. printf(-1, ...) doesn't really "work". It just doesn't give an error like it should. No output is produced. It's easy to fix. -2, +3 etc. all give errors. -1 is a special case in the printf code. It's not handled right. puts(-1, ...) correctly gives an error. Thanks, Rob Craig Rapid Deployment Software http://www.RapidEuphoria.com