what is the difference between the fopen and open functions?
This is a discussion on fopen and open within the Linux Programming forums, part of the Platform Specific Boards category; what is the difference between the fopen and open functions?...
what is the difference between the fopen and open functions?
>what is the difference between the fopen and open functions?
A world.
No, seriously. But the cosmetic differences can be gleaned by looking at the prototypes of each function. The most immediate difference is that fopen returns a FILE * while open returns an int.
My best code is written with the delete key.
Also, open() is defined by POSIX and fopen() is ISO-standard C (89/99).
In some *nix flavors, open() is the interface to the OS. In those systems, fopen() would be implemented by making calls to open().
gg