Create backing image with mode 0644 instead of 0755 & document this.

This commit is contained in:
pooka 2011-02-03 11:25:27 +00:00
parent 53c3cffec5
commit a9061c30c5
2 changed files with 6 additions and 5 deletions

View File

@ -1,4 +1,4 @@
.\" $NetBSD: rump_allserver.1,v 1.10 2011/02/03 11:21:43 pooka Exp $
.\" $NetBSD: rump_allserver.1,v 1.11 2011/02/03 11:25:27 pooka Exp $
.\"
.\" Copyright (c) 2010 Antti Kantee. All rights reserved.
.\"
@ -105,7 +105,8 @@ In case this parameter is not given, the default value 0 is used.
.Pp
In case
.Ar hostpath
does not exist, it will be created as a regular file.
does not exist, it will be created as a regular file with mode
0644 (plus any restrictions placed by umask).
In case
.Ar hostpath
is a regular file and is not large enough to accommodate the

View File

@ -1,4 +1,4 @@
/* $NetBSD: rump_allserver.c,v 1.14 2011/02/03 11:21:16 pooka Exp $ */
/* $NetBSD: rump_allserver.c,v 1.15 2011/02/03 11:25:27 pooka Exp $ */
/*-
* Copyright (c) 2010 Antti Kantee. All Rights Reserved.
@ -27,7 +27,7 @@
#include <sys/cdefs.h>
#ifndef lint
__RCSID("$NetBSD: rump_allserver.c,v 1.14 2011/02/03 11:21:16 pooka Exp $");
__RCSID("$NetBSD: rump_allserver.c,v 1.15 2011/02/03 11:25:27 pooka Exp $");
#endif /* !lint */
#include <sys/types.h>
@ -266,7 +266,7 @@ main(int argc, char *argv[])
int fd;
fsize = etfs[i].foffset + etfs[i].flen;
fd = open(etfs[i].hostpath, O_RDWR | O_CREAT, 0755);
fd = open(etfs[i].hostpath, O_RDWR | O_CREAT, 0644);
if (fd == -1)
die(sflag, errno, "etfs hostpath create");
if (fstat(fd, &sb) == -1)