bug-gift
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-GIFT] Socket trouble. Was: error using CFeedbackClient


From: Wolfgang Mueller
Subject: Re: [bug-GIFT] Socket trouble. Was: error using CFeedbackClient
Date: Thu, 8 Mar 2001 11:26:10 +0100 (CET)

>>>>> "HM" == Henning Mueller <address@hidden> writes:

HM> Hi,
HM> yes, it happens when the result size is very long. The transmitted lists
HM> contain around 900 elements where each element is at least 100 bytes. I
HM> tried it out with the Geneva server (Port 12790) as well and I get the
HM> same error.

This is quite strange. 

HM> All the patches I send are for the newest version, as you might have
HM> noticed. I always check out the newest version from the savannah server.

Oh, sorry, I just saw that the path of your patch goes to
gift-0.1.5pre this seemed to suggest that you patch against 0.1.5pre.
Please don't be offended, patching against too old stuff is a
classical error on all the mailing lists I am on, so this message was
also to remind other bugreporters...

HM> Still I do not want to recompile and restart the server, whenever there
HM> is something new. 

Interesting.

HM> The server logfiles are all OK, so the server seems to send out te
HM> correct information, but on the CFeedbackClient side the XML Parser is
HM> called before the message is finished.
HM> This actually did work in december when I did the same tests in Geneva
HM> before christmas, even with much larger return sets of up to 6000
HM> images.

To show you the interesting part of GIFTServer/Server.cc:

  // this stuff was there before
  cout << "shutting down the socket!"
       << endl;
  //shutdown for write
  if(shutdown(lParameters->mSocket,1)){
    cerr << "Shutdown 1 failed: " << strerror(errno) << endl;
  }
  // this stuff is new for better tear down??
  cout << "waitreadstream (I)" << endl;
  // wait if we can read (what we would read would be an EOF)
  waitReadStream(lParameters->mSocket);
  cout << "waitreadstream (II)" << endl;
  //sleep(1); // <------ this is the interesting line
  close(lParameters->mSocket);

In the version which worked for you, there was this *embarassing* wait
of one second before closing. Which I hope to avoid by waiting for an
eof from the client. I guess I would have to TEST that it really is an
eof. This will come soon.(If somebody with real socket expertise is
reading this, maybe she/he could help us?). 

Cheers,
Wolfgang

-- 
Wolfgang M&uuml;ller, 
assistant-doctorant ==  PhD student (2001), teaching assistant
Personal page: http://cui.unige.ch/~vision/members/WolfgangMueller.html 
Maintainer, GNU Image Finding Tool (http://www.gnu.org/software/gift)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]