diff options
author | Christopher Faylor <me@cgf.cx> | 2005-12-19 04:00:41 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2005-12-19 04:00:41 +0000 |
commit | ca9271d1b6c70a60640e32a2cdb729d51e2037e7 (patch) | |
tree | df73e4e96c28d32d494a04aa7f520e2e5b9a98d7 | |
parent | ad02bb70e389235036436b8d3f3983b0cd5c1320 (diff) | |
download | newlib-ca9271d1b6c70a60640e32a2cdb729d51e2037e7.zip newlib-ca9271d1b6c70a60640e32a2cdb729d51e2037e7.tar.gz newlib-ca9271d1b6c70a60640e32a2cdb729d51e2037e7.tar.bz2 |
* include/sys/dirent.h: Change __deprecated_d_ino to __invalid_d_ino throughout
to make things a little clearer.
* dir.cc (readdir_worker): Reflect above change.
-rw-r--r-- | winsup/cygwin/ChangeLog | 6 | ||||
-rw-r--r-- | winsup/cygwin/dir.cc | 14 | ||||
-rw-r--r-- | winsup/cygwin/include/sys/dirent.h | 6 |
3 files changed, 16 insertions, 10 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index e2c2c77..f29d97e 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,9 @@ +2005-12-18 Christopher Faylor <cgf@timesys.com> + + * include/sys/dirent.h: Change __deprecated_d_ino to __invalid_d_ino + throughout to make things a little clearer. + * dir.cc (readdir_worker): Reflect above change. + 2005-12-16 Christopher Faylor <cgf@timesys.com> * winsup.h (child_copy): Change prototype to match new functionality. diff --git a/winsup/cygwin/dir.cc b/winsup/cygwin/dir.cc index a5ac1a2..7682233 100644 --- a/winsup/cygwin/dir.cc +++ b/winsup/cygwin/dir.cc @@ -103,18 +103,18 @@ readdir_worker (DIR *dir, dirent *de) if (!res) if (!CYGWIN_VERSION_CHECK_FOR_NEEDS_D_INO) { - de->__deprecated_d_ino = 0; + de->__invalid_d_ino = 0; de->__ino32 = 0; } else { - /* Compute __deprecated_d_ino by combining filename hash with the directory hash + /* Compute __invalid_d_ino by combining filename hash with the directory hash (which was stored in dir->__d_dirhash when opendir was called). */ if (de->d_name[0] == '.') { if (de->d_name[1] == '\0') { - de->__deprecated_d_ino = dir->__d_dirhash; + de->__invalid_d_ino = dir->__d_dirhash; dir->__flags |= dirent_saw_dot; } else if (de->d_name[1] != '.' || de->d_name[2] != '\0') @@ -128,11 +128,11 @@ readdir_worker (DIR *dir, dirent *de) goto hashit; *p = '\0'; if (!(p = strrchr (up, '\\'))) - de->__deprecated_d_ino = hash_path_name (0, "."); + de->__invalid_d_ino = hash_path_name (0, "."); else { *p = '\0'; - de->__deprecated_d_ino = hash_path_name (0, up); + de->__invalid_d_ino = hash_path_name (0, up); } } } @@ -140,9 +140,9 @@ readdir_worker (DIR *dir, dirent *de) { hashit: __ino64_t dino = hash_path_name (dir->__d_dirhash, "\\"); - de->__deprecated_d_ino = hash_path_name (dino, de->d_name); + de->__invalid_d_ino = hash_path_name (dino, de->d_name); } - de->__ino32 = de->__deprecated_d_ino; // for legacy applications + de->__ino32 = de->__invalid_d_ino; // for legacy applications } return res; } diff --git a/winsup/cygwin/include/sys/dirent.h b/winsup/cygwin/include/sys/dirent.h index c53650a..d64ebe8 100644 --- a/winsup/cygwin/include/sys/dirent.h +++ b/winsup/cygwin/include/sys/dirent.h @@ -20,7 +20,7 @@ struct dirent { long d_version; /* Used since Cygwin 1.3.3. */ - __ino64_t __deprecated_d_ino; + __ino64_t __invalid_d_ino; long d_fd; /* File descriptor of open directory. Used since Cygwin 1.3.3. */ unsigned __ino32; @@ -31,7 +31,7 @@ struct dirent struct dirent { long d_version; - ino_t __deprecated_d_ino; + ino_t __invalid_d_ino; long d_fd; unsigned long __ino32; char d_name[256]; @@ -42,7 +42,7 @@ struct dirent long d_version; long d_reserved[2]; long d_fd; - ino_t __deprecated_d_ino; + ino_t __invalid_d_ino; char d_name[256]; }; #endif |