try {
channels = new ISOChannel[sessions];
for (int i=0; i<sessions; i++) {
ISOChannel c = initChannel();
if (c instanceof LogSource) {
LogSource ls = ((LogSource) c);
ls.setLogger(ls.getLogger(), ls.getRealm()+"-"+i);
}
channels[i] = c;
if (!writeOnly)
new Thread (new Receiver (i), "channel-receiver-" + in + "-" + i).start ();