From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10437 invoked by alias); 22 Jul 2002 08:20:21 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 10385 invoked from network); 22 Jul 2002 08:20:16 -0000 Received: from unknown (HELO ns1.3rdplanetsoftware.com) (64.81.39.61) by sources.redhat.com with SMTP; 22 Jul 2002 08:20:16 -0000 Received: from 3rdplanetsoftware.com (danny [192.168.1.2]) by ns1.3rdplanetsoftware.com (8.10.2/8.10.2) with ESMTP id g6M8LAP16465; Mon, 22 Jul 2002 01:21:10 -0700 Message-ID: <3D3BBB6D.7BE2639E@3rdplanetsoftware.com> Date: Mon, 22 Jul 2002 01:20:00 -0000 From: danny X-Accept-Language: en MIME-Version: 1.0 To: Rupert Wood CC: gcc-help@gcc.gnu.org Subject: Re: directories for newbies References: <616BE6A276E3714788D2AC35C40CD18D5EC520@whale.softwire.co.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2002-07/txt/msg00219.txt.bz2 Hey Now Rupert, Thanks for the stat function. U referred to section 1 & 2. What book is this? Thanks Danny Rupert Wood wrote: > Danny wrote: > > > I'm look for a function to get me the attributes of a file. Such as is > > the file a directory or not. Any ideas? > > Stat(); test for the S_IFDIR bit set in st_mode. See the manual pages > for stat and the mknod function (in section 2 - not the mknod utility in > section 1). > > Rup.