From 8cf4f4e3595db05c4fc791dd3ac9d3789057dcfe Mon Sep 17 00:00:00 2001 From: christos Date: Mon, 16 Oct 2006 03:21:05 +0000 Subject: [PATCH] c99 initializers --- sbin/fsck_lfs/dir.c | 29 +++++++++++++++++++++++------ 1 file changed, 23 insertions(+), 6 deletions(-) diff --git a/sbin/fsck_lfs/dir.c b/sbin/fsck_lfs/dir.c index a2a714385281..014f24c02e1d 100644 --- a/sbin/fsck_lfs/dir.c +++ b/sbin/fsck_lfs/dir.c @@ -1,4 +1,4 @@ -/* $NetBSD: dir.c,v 1.20 2006/09/01 19:52:48 perseant Exp $ */ +/* $NetBSD: dir.c,v 1.21 2006/10/16 03:21:05 christos Exp $ */ /* * Copyright (c) 1980, 1986, 1993 @@ -55,14 +55,31 @@ const char *lfname = "lost+found"; int lfmode = 01700; -struct dirtemplate emptydir = {0, DIRBLKSIZ}; +struct dirtemplate emptydir = { + .dot_ino = 0, + .dot_reclen = DIRBLKSIZ, +}; struct dirtemplate dirhead = { - 0, 12, DT_DIR, 1, ".", - 0, DIRBLKSIZ - 12, DT_DIR, 2, ".." + .dot_ino = 0, + .dot_reclen = 12, + .dot_type = DT_DIR, + .dot_namlen = 1, + .dot_name = ".", + .dotdot_ino = 0, + .dotdot_reclen = DIRBLKSIZ - 12, + .dotdot_type = DT_DIR, + .dotdot_namlen = 2, + .dotdot_name = ".." }; struct odirtemplate odirhead = { - 0, 12, 1, ".", - 0, DIRBLKSIZ - 12, 2, ".." + .dot_ino = 0, + .dot_reclen = 12, + .dot_namlen = 1, + .dot_name = ".", + .dotdot_ino = 0, + .dotdot_reclen = DIRBLKSIZ - 12, + .dotdot_namlen = 2, + .dotdot_name = ".." }; static int expanddir(struct uvnode *, struct ufs1_dinode *, char *);