From 48747c6894707b2bfb10031f3eca4bcf90da46c4 Mon Sep 17 00:00:00 2001 From: hannken Date: Tue, 26 Apr 2022 15:36:42 +0000 Subject: [PATCH] Fix default quota file names, both user and group quota used the same default name "QUOTAFILENAME, names[USRQUOTA])" resulting in diagnostic assertion and possibly corrupted quota data. --- lib/libquota/quota_oldfiles.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/libquota/quota_oldfiles.c b/lib/libquota/quota_oldfiles.c index e2a171295558..76a6bbd7ba80 100644 --- a/lib/libquota/quota_oldfiles.c +++ b/lib/libquota/quota_oldfiles.c @@ -1,4 +1,4 @@ -/* $NetBSD: quota_oldfiles.c,v 1.9 2012/02/24 18:00:09 njoly Exp $ */ +/* $NetBSD: quota_oldfiles.c,v 1.10 2022/04/26 15:36:42 hannken Exp $ */ /* * Copyright (c) 1980, 1990, 1993 @@ -33,7 +33,7 @@ */ #include -__RCSID("$NetBSD: quota_oldfiles.c,v 1.9 2012/02/24 18:00:09 njoly Exp $"); +__RCSID("$NetBSD: quota_oldfiles.c,v 1.10 2022/04/26 15:36:42 hannken Exp $"); #include #include @@ -255,7 +255,7 @@ __quota_oldfiles_defquotafile(struct quotahandle *qh, int idtype, (void)snprintf(buf, maxlen, "%s/%s.%s", qh->qh_mountpoint, - QUOTAFILENAME, names[USRQUOTA]); + QUOTAFILENAME, names[idtype]); } const char *