Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <01fe01c089a6$09101800$0200a8c0@voyager> From: "Trevor Forbes" To: References: <20010128161343 DOT A20664 AT redhat DOT com> <018301c08986$a4100470$0200a8c0 AT voyager> <20010128190458 DOT A26380 AT redhat DOT com> <20010128194208 DOT A27804 AT redhat DOT com> Subject: Re: changes in 2001-01-27 snapshot -- test suite question Date: Mon, 29 Jan 2001 13:16:15 +0930 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 I have reduced the /dev/zero test case (devzero.c) down to the area of interest. Not being an expert, but mmap seems to be returning an address which is out of bounds. I am still having problems debugging the cygwin1.dll so this is as far as I can go at the moment. I hope this is of some use. Regards Trevor ------------------------devzero.c #include #include #include #include #include main() { int fd, r, w, l; char buf[1024]; char *v; fd = open("/dev/zero", O_RDWR); v = (char *)mmap(0, 65536, PROT_READ|PROT_WRITE, MAP_PRIVATE, fd, 0); if (v == (char *)-1) { fprintf(stderr, "mmap r/w /dev/zero failed\n"); perror("The error was"); exit(1); } for (r=0; r<65536; r++) if (v[r] != 0) { fprintf(stderr, "mmap'd r/w /dev/zero has byte %d at offset %d\n", v[r], r); exit(1); } munmap(v, 65536); close(fd); exit(0); } -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple