delorie.com/archives/browse.cgi | search |
X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
From: | Jim Michaels <jmichae3 AT yahoo DOT com> |
Newsgroups: | comp.os.msdos.djgpp |
Subject: | Re: dirent structure wrong according to online documentation |
Date: | Mon, 5 Jan 2009 00:26:48 -0800 (PST) |
Organization: | http://groups.google.com |
Lines: | 31 |
Message-ID: | <22e6bf83-f793-4ffc-855d-d1dad838c578@e1g2000pra.googlegroups.com> |
References: | <45698add-916e-4b28-89af-80eb795bba60 AT z27g2000prd DOT googlegroups DOT com> |
<200901040903 DOT n0493pTa030645 AT envy DOT delorie DOT com> | |
NNTP-Posting-Host: | 76.115.70.155 |
Mime-Version: | 1.0 |
X-Trace: | posting.google.com 1231144008 32621 127.0.0.1 (5 Jan 2009 08:26:48 GMT) |
X-Complaints-To: | groups-abuse AT google DOT com |
NNTP-Posting-Date: | Mon, 5 Jan 2009 08:26:48 +0000 (UTC) |
Complaints-To: | groups-abuse AT google DOT com |
Injection-Info: | e1g2000pra.googlegroups.com; posting-host=76.115.70.155; |
posting-account=05hOMwoAAAB6R8xtiQKzEljSMzgOhVF1 | |
User-Agent: | G2/1.0 |
X-HTTP-UserAgent: | Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.5) |
Gecko/2008120122 Firefox/3.0.5,gzip(gfe),gzip(gfe) | |
To: | djgpp AT delorie DOT com |
DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id n058U3lT009183 |
Reply-To: | djgpp AT delorie DOT com |
On Jan 4, 1:03 am, DJ Delorie <d DOT DOT DOT AT delorie DOT com> wrote: > >http://www.delorie.com/djgpp/doc/libc/libc_646.html > > states that the directory structure doesn't have d_type > > Actually, it states that it does have d_type. > > > please put it back in dirent.h and associated files please. (libc.a) > > I can't put it "back" since it's already in there. #include <dirent.h> #include <stdio.h> int main(void) { DIR *d = opendir("."); struct dirent *de; while (de = readdir(d)) if (de->d_type) printf("directory "); else printf("file "); closedir(d); return 0; } d.cpp: In function 'int main()': d.cpp:7: error: 'struct dirent' has no member named 'd_type' I checked the header file myself. it's not there. there are only 2 entries in the structure. (the 1998 revision). I tried to make sure I used the latest zip files from current. this is with gpp 4.32. Jim Michaels
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |