From owner-freebsd-hackers Wed Jan 16 12:23:54 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from falcon.prod.itd.earthlink.net (falcon.mail.pas.earthlink.net [207.217.120.74]) by hub.freebsd.org (Postfix) with ESMTP id C600337B400 for ; Wed, 16 Jan 2002 12:23:49 -0800 (PST) Received: from pool0454.cvx21-bradley.dialup.earthlink.net ([209.179.193.199] helo=mindspring.com) by falcon.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 16Qwaw-0002o1-00; Wed, 16 Jan 2002 12:23:38 -0800 Message-ID: <3C45E148.5164B465@mindspring.com> Date: Wed, 16 Jan 2002 12:23:36 -0800 From: Terry Lambert X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Foldi Tamas Cc: freebsd-hackers@freebsd.org Subject: Re: interesting open() issue References: <20020116105923.A29210@hax0r.hu> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Foldi Tamas wrote: > > Hello hackers, > > I tried the following program on Tru64, FreeBSD and linux: > > #include > #include > #include > #include > main() { > int fd; > fd = open ( "/tmp/foobar", (O_RDWR | O_CREAT), 0020); > perror("open"); > close(fd); > } > > The program ran successfully, but the created file was different. > On Linux: > -----w---- 1 crow crow 0 Jan 16 10:32 /tmp/foobar > > On Tru64/FreeBSD: > ---------- 1 crow users 0 Jan 16 10:30 /tmp/foobar > > I'm not sure what the result supposed to be. Any ideas ? man 2 umask -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message