Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 4 Jan 2012 07:21:37 +0000 (UTC)
From:      Pawel Jakub Dawidek <pjd@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r229467 - head/usr.sbin/uhsoctl
Message-ID:  <201201040721.q047LbnF065866@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pjd
Date: Wed Jan  4 07:21:37 2012
New Revision: 229467
URL: http://svn.freebsd.org/changeset/base/229467

Log:
  Add an missing argument to open(2). If O_CREAT flag is specified,
  file permission has to be specified as well.

Modified:
  head/usr.sbin/uhsoctl/uhsoctl.c

Modified: head/usr.sbin/uhsoctl/uhsoctl.c
==============================================================================
--- head/usr.sbin/uhsoctl/uhsoctl.c	Wed Jan  4 07:04:43 2012	(r229466)
+++ head/usr.sbin/uhsoctl/uhsoctl.c	Wed Jan  4 07:21:37 2012	(r229467)
@@ -455,7 +455,7 @@ set_nameservers(struct ctx *ctx, const c
 		free(ctx->ns);
 	}
 
-	fd = open(respath, O_RDWR | O_CREAT | O_NOFOLLOW);
+	fd = open(respath, O_RDWR | O_CREAT | O_NOFOLLOW, 0666);
 	if (fd < 0)
 		return (-1);
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201201040721.q047LbnF065866>