-$Id: CHANGES,v 1.36 2000/01/21 10:33:40 stelian Exp $
+$Id: CHANGES,v 1.37 2000/01/25 14:14:12 stelian Exp $
+
+Changes between versions 0.4b13 and 0.4b14 (released ????????????????)
+======================================================================
+
+1. Fixed a bug in dump which may have caused invalid deleted
+ directories to be dumped out if they were deleted after the
+ mapping pass. This could occure on active filesystem and lead
+ to heap corruption (causing dump malfunction in many possible ways).
+ Thanks to Jan Sanislo <oystr@cs.washington.edu> for finding this
+ bug and submitting the patch.
Changes between versions 0.4b12 and 0.4b13 (released January 21, 2000)
======================================================================
#ifndef lint
static const char rcsid[] =
- "$Id: main.c,v 1.12 2000/01/21 10:17:41 stelian Exp $";
+ "$Id: main.c,v 1.13 2000/01/25 14:14:12 stelian Exp $";
#endif /* not lint */
#include <sys/param.h>
if ((dp->di_mode & IFMT) != IFDIR)
continue;
#ifdef __linux__
+ /*
+ * Skip directory inodes deleted and not yes reallocated...
+ */
+ if (dp->di_nlink == 0 || dp->di_dtime != 0)
+ continue;
(void)dumpdirino(dp, ino);
#else
(void)dumpino(dp, ino);
msg("dumping (Pass IV) [regular files]\n");
for (map = dumpinomap, ino = 1; ino < maxino; ino++) {
- int mode;
-
if (((ino - 1) % NBBY) == 0) /* map is offset by 1 */
dirty = *map++;
else
* Skip inodes deleted and reallocated as directories.
*/
dp = getino(ino);
- mode = dp->di_mode & IFMT;
- if (mode == IFDIR)
+ if ((dp->di_mode & IFMT) == IFDIR)
continue;
+#ifdef __linux__
+ /*
+ * No need to check here for deleted and not yes reallocated inodes
+ * since this is done in dumpino().
+ */
+#endif
(void)dumpino(dp, ino);
}