Recent

Author Topic: Need help!LNet bug?  (Read 4916 times)

pathletboy

  • Newbie
  • Posts: 2
Need help!LNet bug?
« on: March 02, 2010, 02:44:08 pm »
try these code on ubuntu9.10
Code: [Select]
program lclient;

{$mode objfpc}{$H+}

uses
  Classes, Crt, SysUtils, lNet, lnetbase;

var
TCP: TLTCP;
  i: Integer;
begin

i := 0;
while true do
  begin
  TCP := TLTCP.Create(nil);
  TCP.Connect('127.0.0.1',55002);
  TCP.Free;
  Inc(i);
  Writeln(IntToStr(i));
  end;
end.
it will raise a exception.
Quote
Exception : Unable to create epoll : Too many open files

i want to know,why?

pathletboy

  • Newbie
  • Posts: 2
Re: Need help!LNet bug?
« Reply #1 on: March 03, 2010, 12:58:06 pm »
i am sure it is a bug.
bug in file lepolleventer.inc
line between 23 to 50
FEpollReadFD and FEpollMasterFD created but without close.

Almindor

  • Sr. Member
  • ****
  • Posts: 412
    • http://www.astarot.tk
Re: Need help!LNet bug?
« Reply #2 on: March 17, 2011, 08:37:13 pm »
Indeed a nice find too. I have fixed it in trunk and am currently investigating other eventers for such forgotten FD closes.

If you agree, I'll include your stress-test program in my tests dir.

Thanks again for reporting.

 

TinyPortal © 2005-2018