From 44cb5d116ac6c97075da69a5981176513e45ca49 Mon Sep 17 00:00:00 2001 From: pjd Date: Wed, 4 Jan 2012 07:04:43 +0000 Subject: [PATCH] Add an missing argument to open(2). If O_CREAT flag is specified, file permission has to be specified as well. --- usr.sbin/mptable/mptable.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.sbin/mptable/mptable.c b/usr.sbin/mptable/mptable.c index 92279bc1a77daf..3c38ccfa4d5ae2 100644 --- a/usr.sbin/mptable/mptable.c +++ b/usr.sbin/mptable/mptable.c @@ -828,7 +828,7 @@ MPConfigTableHeader( u_int32_t pap ) int ofd; u_char dumpbuf[ 4096 ]; - ofd = open( "/tmp/mpdump", O_CREAT | O_RDWR ); + ofd = open( "/tmp/mpdump", O_CREAT | O_RDWR, 0666 ); seekEntry( paddr ); readEntry( dumpbuf, 1024 ); write( ofd, dumpbuf, 1024 );