def process_incoming_message(data)
TheLog.debug("Processing incoming message, #{data.length} bytes")
ans=nil
begin
ans = Message.decode(data)
rescue Exception => e
TheLog.error("Decode error! #{e.class}, #{e}\nfor msg (length=#{data.length}) : #{data}")
@closing=true
close_connection
send_to_client(nil, e)
return
end
TheLog.debug("#{ans}")
ans.answerfrom=(@args[:server])
ans.answersize=(data.length)
exception = ans.header.get_exception
@closing=true
close_connection
send_to_client(ans, exception)
end