Version 2.21/08
==================
Dear ROOTers,
I have few questions concerning the TSocket::Send(..) method.
Supposedly we do establish a socket connection between A & B, and kill B
immediately afterwards. Now, when we try to send something from A to B
like:
root [3] sock->Send("hello")
we get:
(Int_t)6
Which already is not true, since the connection was broken and I would
expect to receive (-1). However, when we try to send something again
e.g..:
root [4] sock->Send("hello")
we get:
*** Break *** write on a pipe with no one to read it
SysError in <TUnixSystem::UnixSend>: send (Broken pipe)
Error in <TUnixSystem::SendRaw>: cannot send buffer
(Int_t)(-1)
So my questions are:
(-) is it a bug, or am I missing some important point in socket
communication
(-) is it possible to eliminate this message which appears above - in
my program, when I get return value of (-1) I know that we have problems
so I handle the situation, and I would prefer that the user would not be
scared with those messages
(-) TSocket::IsValid() returns kTRUE in both cases, probably because
the
socket is still opened. However, the documentation does not specify
exactly when IsValid() returns kTRUE, and intuitively to me it's no
longer
valid since we can no longer send things to it.
Thank you in advance for your help,
Krzysztof
--------------B43ACAE62990FB0423BADCCE
Content-Type: text/x-vcard; charset=us-ascii;
name="Krzysztof.Zelazowski.vcf"
Content-Transfer-Encoding: 7bit
Content-Description: Card for Krzysztof Zelazowski
Content-Disposition: attachment;
filename="Krzysztof.Zelazowski.vcf"
begin:vcard
n:Zelazowski;Krzysztof
x-mozilla-html:TRUE
org:CERN. European Lab. for Particle Physics;div: EP
adr:;;;;;;
version:2.1
email;internet:Krzysztof.Zelazowski@cern.ch
title:Technical Student
x-mozilla-cpt:;-15920
fn:Krzysztof Zelazowski
end:vcard
--------------B43ACAE62990FB0423BADCCE--