www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rolf Hoppe <rolf.ho...@thieme.de>
Subject mod_cgi/1876: Out of file descriptors on subsequent CGI runs
Date Thu, 26 Feb 1998 15:58:24 GMT

>Number:         1876
>Category:       mod_cgi
>Synopsis:       Out of file descriptors on subsequent CGI runs
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Thu Feb 26 09:10:00 PST 1998
>Last-Modified:
>Originator:     rolf.hoppe@thieme.de
>Organization:
apache
>Release:        1.3b3 Win95
>Environment:
Apache_1_3b3_win32.exe under  Windows 95
>Description:
The file descriptor value is increased on every CGI script call by 3, causing out of fd's
error after a few runs. No files can be opened any more.
>How-To-Repeat:
Test-C Program:

#include <io.h>
#include <stdio.h>
#include <fcntl.h>

main()
{
  int	fd;
  printf ("Content-Type: TEXT/HTML\n\n");
  fd = open ("??ANYFILE", O_RDONLY|O_BINARY);
  printf ("fd is %d", fd);
  close (fd);
  return 0;
}

>Fix:
fd's 0 to 2 are not closed after CGI run%3
>Audit-Trail:
>Unformatted:
[In order for any reply to be added to the PR database, ]
[you need to include <apbugs@Apache.Org> in the Cc line ]
[and leave the subject line UNCHANGED.  This is not done]
[automatically because of the potential for mail loops. ]




Mime
View raw message