From 49840169c01c5467f84c3ff63f45c37ebcd9ceb1 Mon Sep 17 00:00:00 2001 From: christos Date: Mon, 12 Sep 2005 20:26:44 +0000 Subject: [PATCH] Add another KASSERT. --- sys/ufs/ffs/ffs_inode.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/sys/ufs/ffs/ffs_inode.c b/sys/ufs/ffs/ffs_inode.c index 8322d280e1db..f4a4970e0346 100644 --- a/sys/ufs/ffs/ffs_inode.c +++ b/sys/ufs/ffs/ffs_inode.c @@ -1,4 +1,4 @@ -/* $NetBSD: ffs_inode.c,v 1.74 2005/09/12 20:09:59 drochner Exp $ */ +/* $NetBSD: ffs_inode.c,v 1.75 2005/09/12 20:26:44 christos Exp $ */ /* * Copyright (c) 1982, 1986, 1989, 1993 @@ -32,7 +32,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: ffs_inode.c,v 1.74 2005/09/12 20:09:59 drochner Exp $"); +__KERNEL_RCSID(0, "$NetBSD: ffs_inode.c,v 1.75 2005/09/12 20:26:44 christos Exp $"); #if defined(_KERNEL_OPT) #include "opt_ffs.h" @@ -654,6 +654,9 @@ ffs_itimes(struct inode *ip, const struct timespec *acc, const struct timespec *mod, const struct timespec *cre) { struct timespec *ts = NULL, tsb; + + KASSERT(ip->i_flag & (IN_ACCESS | IN_CHANGE | IN_UPDATE | IN_MODIFY)); + if (ip->i_flag & IN_ACCESS) { if (acc == NULL) acc = ts == NULL ? (ts = nanotime(&tsb)) : ts;