delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
Date: | Fri, 7 Jun 2002 17:21:45 -0400 (EDT) |
From: | David E Euresti <davie AT MIT DOT EDU> |
To: | <cygwin AT cygwin DOT com> |
Subject: | fstat on sockets broken |
Message-ID: | <Pine.GSO.4.30L.0206071714090.16420-100000@scrubbing-bubbles.mit.edu> |
MIME-Version: | 1.0 |
Hello, The following code returns with fstat: No such file or directory which is not what unix does. I can work around it but just thought I'd let you know. #include <stdio.h> #include <sys/socket.h> #include <sys/types.h> #include <sys/stat.h> #include <errno.h> int main() { struct stat sbuf; int fd = socket(AF_INET, SOCK_STREAM, 0); if (fstat(fd, &sbuf) < 0) { printf("fstat: %s\n", strerror(errno)); exit(0); } } David -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Bug reporting: http://cygwin.com/bugs.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |