summaryrefslogtreecommitdiff
path: root/src/tac.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2004-12-14 10:28:03 +0000
committerJim Meyering <jim@meyering.net>2004-12-14 10:28:03 +0000
commit9a13cce9ec3bd1f96cef1a043194bd5524bbb4c4 (patch)
treeb1f193d038b78bd4955a802103d623a45ecc5f4b /src/tac.c
parentb4062c8a22f8c436bbb75638603ab38fd0edad09 (diff)
downloadcoreutils-9a13cce9ec3bd1f96cef1a043194bd5524bbb4c4.tar.xz
[DONT_UNLINK_WHILE_OPEN]: Add a FIXME comment explaining that
using atexit like this is wrong.
Diffstat (limited to 'src/tac.c')
-rw-r--r--src/tac.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/tac.c b/src/tac.c
index ba206c1ef..4f6fb229a 100644
--- a/src/tac.c
+++ b/src/tac.c
@@ -375,6 +375,12 @@ tac_seekable (int input_fd, const char *file)
#if DONT_UNLINK_WHILE_OPEN
+/* FIXME-someday: remove all of this DONT_UNLINK_WHILE_OPEN junk.
+ Using atexit like this is wrong, since it can fail
+ when called e.g. 32 or more times.
+ But this isn't a big deal, since the code is used only on WOE/DOS
+ systems, and few people invoke tac on that many nonseekable files. */
+
static const char *file_to_remove;
static FILE *fp_to_close;