Behaviour of fflush() on a file opened for reading

Colin Percival colin.percival at
Thu Apr 15 05:29:01 PDT 2004

  PR kern/65402 complains about fflush() failing if called
on a file opened read-only.  Our libc returns an error; many
do not.  According to the ISO C standard, behaviour here is
  Should we change our behaviour to meet the expectations of
broken programs?  In order to avoid creating lots of noise
on the list, please reply to me directly.

Colin Percival

More information about the freebsd-current mailing list