Merge "implement missing seekdir and telldir"
authorYabin Cui <yabinc@google.com>
Wed, 12 Nov 2014 20:36:25 +0000 (20:36 +0000)
committerGerrit Code Review <noreply-gerritcodereview@google.com>
Wed, 12 Nov 2014 20:36:26 +0000 (20:36 +0000)
1  2 
libc/include/dirent.h

diff --combined libc/include/dirent.h
index 4ca3a7d4f9e756bcc8a9f4ba23d0178c2af99c7f,820558a77e285be08733689a17a28e3512aef47a..63716a4b7cbcd108019d4f1139ba3b7040186a72
@@@ -58,12 -58,6 +58,12 @@@ struct dirent64 { __DIRENT64_BODY }
  
  #undef __DIRENT64_BODY
  
 +/* glibc compatibility. */
 +#undef _DIRENT_HAVE_D_NAMLEN /* Linux doesn't have a d_namlen field. */
 +#define _DIRENT_HAVE_D_RECLEN
 +#define _DIRENT_HAVE_D_OFF
 +#define _DIRENT_HAVE_D_TYPE
 +
  #define d_fileno d_ino
  
  typedef struct DIR DIR;
@@@ -76,6 -70,8 +76,8 @@@ extern int readdir_r(DIR*, struct diren
  extern int readdir64_r(DIR*, struct dirent64*, struct dirent64**);
  extern int closedir(DIR*);
  extern void rewinddir(DIR*);
+ extern void seekdir(DIR*, long);
+ extern long telldir(DIR*);
  extern int dirfd(DIR*);
  extern int alphasort(const struct dirent**, const struct dirent**);
  extern int alphasort64(const struct dirent64**, const struct dirent64**);