(struct pending) [st_ino, st_dev]: Remove just-added members.
authorJim Meyering <jim@meyering.net>
Thu, 1 Nov 2001 15:51:53 +0000 (15:51 +0000)
committerJim Meyering <jim@meyering.net>
Thu, 1 Nov 2001 15:51:53 +0000 (15:51 +0000)
commitc4dbc53ec40646d75dd314b3d44237cc05f4b2e0
treee3c2cd96de17dadc589d8d41b79600285716e38b
parent00fc6c9262f1758a054c3a9fc9a3886bd7edc5f4
(struct pending) [st_ino, st_dev]: Remove just-added members.
(queue_directory): Remove just-added 3rd parameter
and associated code, and update callers.
(print_dir): Get dev/inode pair via `fstat (dirfd (reading), ...',
and call visit_dir to detect cycles here.
Push the dev/inode pair onto the new stack.
(dev_ino_obstack): New global.
(DEV_INO_PUSH): New macro.
(dev_ino_pop): New function.
(ASSERT_MATCHING_DEV_INO): New macro.
(visit_dir): Take two parameters (dev,ino), not one `pending'.
(main): Initialized the dev_ino_obstack.
Don't call visit_dir here.
Get the dev/ino pair from the new stack, not from the pending entry.
src/ls.c