truncate()
truncate()
Posted Sep 12, 2009 0:26 UTC (Sat) by cras (guest, #7000)Parent article: POSIX v. reality: A position on O_PONIES
This is actually the first time I consciously noticed the existence of truncate() call. I must have seen
it before when doing "man ftruncate", but it never registered to my mind. Is it actually used by some
real programs? In my over 10 years of programming on Linux I've never had a need for it. If
anything it sounds potentially dangerous to use (TOCTOU race).
it before when doing "man ftruncate", but it never registered to my mind. Is it actually used by some
real programs? In my over 10 years of programming on Linux I've never had a need for it. If
anything it sounds potentially dangerous to use (TOCTOU race).