Browse Source

document why the ftell() should be 5 and not 14

Mike Frysinger 19 years ago
parent
commit
70f5583d23
1 changed files with 2 additions and 0 deletions
  1. 2 0
      test/misc/fdopen.c

+ 2 - 0
test/misc/fdopen.c

@@ -35,6 +35,8 @@ main (int argc, char *argv[])
 
 
   fp = fdopen (fd, "a");
   fp = fdopen (fd, "a");
   assert (fp != NULL);
   assert (fp != NULL);
+  /* SuSv3 says that doing a fdopen() does not reset the file position,
+   * thus the '5' here is correct, not '14'. */
   assert (ftell (fp) == 5);
   assert (ftell (fp) == 5);
 
 
 the_end:
 the_end: