From owner-freebsd-hackers Wed Jan 16 2:41: 9 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from starbug.ugh.net.au (starbug.ugh.net.au [203.31.238.37]) by hub.freebsd.org (Postfix) with ESMTP id 6F63637B404 for ; Wed, 16 Jan 2002 02:41:07 -0800 (PST) Received: by starbug.ugh.net.au (Postfix, from userid 1000) id 30AD8A853; Wed, 16 Jan 2002 21:41:04 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by starbug.ugh.net.au (Postfix) with ESMTP id 2DF9454E3; Wed, 16 Jan 2002 20:41:04 +1000 (EST) Date: Wed, 16 Jan 2002 20:41:04 +1000 (EST) From: Andrew To: Foldi Tamas Cc: freebsd-hackers@freebsd.org Subject: Re: interesting open() issue In-Reply-To: <20020116105923.A29210@hax0r.hu> Message-ID: <20020116203252.P24609-100000@starbug.ugh.net.au> X-WonK: *wibble* MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII 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 On Wed, 16 Jan 2002, Foldi Tamas wrote: > 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 What are you intrested in - the difference in permissions or the difference in group? The permissions are probably due to a different umask being set...you could call umask(0) before the open call to make sure it the user's umask has no effect. The difference in group owenership will be due to the permissions on /tmp and the BSD/SysV family differences. This is documented in a man page somewhere I think although I can't find it ATM. It is however documented in APUE. Andrew To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message