[3884] in arla-drinkers

home help back first fref pref prev next nref lref last post

Re: For us who run more than one client at a time

daemon@ATHENA.MIT.EDU (Horst Birthelmer)
Fri Apr 21 06:26:04 2006

From arla-drinkers-bounces@stacken.kth.se Fri Apr 21 10:26:04 2006
Return-Path: <arla-drinkers-bounces@stacken.kth.se>
Delivered-To: arla-drinkers-mtg@bloom-picayune.mit.edu
Received: (qmail 16989 invoked from network); 21 Apr 2006 10:26:04 -0000
Received: from mx3.kth.se (130.237.48.97)
  by charon.mit.edu with SMTP; 21 Apr 2006 10:26:04 -0000
Received: from localhost (localhost.localdomain [127.0.0.1])
	by mx3.kth.se (Postfix) with ESMTP id E5B9D140A49;
	Fri, 21 Apr 2006 12:26:02 +0200 (CEST)
Received: from mx3.kth.se ([127.0.0.1])
 by localhost (mx3.kth.se [127.0.0.1]) (amavisd-new, port 10024) with LMTP
 id 22680-01-15; Fri, 21 Apr 2006 12:26:01 +0200 (CEST)
Received: from tapas.stacken.kth.se (tapas.stacken.kth.se [130.237.234.140])
	by mx3.kth.se (Postfix) with ESMTP id 3D6CE14093A;
	Fri, 21 Apr 2006 12:26:01 +0200 (CEST)
Received: from tapas.stacken.kth.se (localhost [127.0.0.1])
	by tapas.stacken.kth.se (Postfix) with ESMTP id 68646534FC;
	Fri, 21 Apr 2006 12:26:03 +0200 (CEST)
X-Original-To: arla-drinkers@tapas.stacken.kth.se
Delivered-To: arla-drinkers@tapas.stacken.kth.se
Received: from brev.stacken.kth.se (brev.stacken.kth.se [130.237.234.84])
	by tapas.stacken.kth.se (Postfix) with ESMTP id 7E673534FC
	for <arla-drinkers@tapas.stacken.kth.se>;
	Fri, 21 Apr 2006 12:26:01 +0200 (CEST)
Received: from mx3.kth.se (mx3.kth.se [130.237.48.97])
	by brev.stacken.kth.se (8.12.10/8.12.10) with ESMTP id k3LAPwBR010441
	for <arla-drinkers@stacken.kth.se>;
	Fri, 21 Apr 2006 12:25:58 +0200 (MET DST)
Received: from localhost (localhost.localdomain [127.0.0.1])
	by mx3.kth.se (Postfix) with ESMTP id 8FBDA140A43
	for <arla-drinkers@stacken.kth.se>;
	Fri, 21 Apr 2006 12:25:57 +0200 (CEST)
Received: from mx3.kth.se ([127.0.0.1])
	by localhost (mx3.kth.se [127.0.0.1]) (amavisd-new,
	port 10024) with LMTP
	id 20242-01-99 for <arla-drinkers@stacken.kth.se>;
	Fri, 21 Apr 2006 12:25:56 +0200 (CEST)
Received: from liberty.phpwebhosting.com (liberty.phpwebhosting.com
	[69.0.209.130]) by mx3.kth.se (Postfix) with SMTP id 9FF65140763
	for <arla-drinkers@stacken.kth.se>;
	Fri, 21 Apr 2006 12:25:54 +0200 (CEST)
Received: (qmail 21077 invoked from network); 21 Apr 2006 10:19:10 -0000
Received: from unknown (HELO [172.16.1.165]) (213.139.154.33)
	by liberty.phpwebhosting.com with (RC4-SHA encrypted) SMTP;
	Fri, 21 Apr 2006 06:19:10 -0400
In-Reply-To: <20060420.171144.51157477.haba@habarber.pdc.kth.se>
References: <20060420.171144.51157477.haba@habarber.pdc.kth.se>
Mime-Version: 1.0 (Apple Message framework v749.3)
Message-Id: <AF86CD0E-EF0B-4711-A331-EBBF232F68DA@riback.net>
From: Horst Birthelmer <horst@riback.net>
Subject: Re: For us who run more than one client at a time
Date: Fri, 21 Apr 2006 12:19:12 +0200
To: Harald Barth <haba@pdc.kth.se>
X-Mailer: Apple Mail (2.749.3)
X-Virus-Scanned: by amavisd-new at kth.se
X-Spam-Status: No, hits=-4.2 tagged_above=-200.0 required=5.0 tests=BAYES_00, 
	RM_bpc_GetForJust
X-Spam-Level: 
Cc: arla-drinkers@stacken.kth.se
X-BeenThere: arla-drinkers@stacken.kth.se
X-Mailman-Version: 2.1.6
Precedence: list
List-Id: Arla discussions <arla-drinkers.stacken.kth.se>
List-Unsubscribe: <https://lists.stacken.kth.se/mailman/listinfo/arla-drinkers>, 
	<mailto:arla-drinkers-request@stacken.kth.se?subject=unsubscribe>
List-Archive: <http://lists.stacken.kth.se/pipermail/arla-drinkers>
List-Post: <mailto:arla-drinkers@stacken.kth.se>
List-Help: <mailto:arla-drinkers-request@stacken.kth.se?subject=help>
List-Subscribe: <https://lists.stacken.kth.se/mailman/listinfo/arla-drinkers>, 
	<mailto:arla-drinkers-request@stacken.kth.se?subject=subscribe>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Sender: arla-drinkers-bounces@stacken.kth.se
Errors-To: arla-drinkers-bounces@stacken.kth.se
X-Virus-Scanned: by amavisd-new at kth.se

On Apr 20, 2006, at 5:11 PM, Harald Barth wrote:
> This will (mis)use the ports above 7001 as callback port
> if 7001 happens to be taken. Is this OK or do we need
> to be more sophisticated?
>
> Harald.
>
> --- arlad/arla.c.orig   2006-04-20 17:00:55.000000000 +0200
> +++ arlad/arla.c        2006-04-20 17:04:27.000000000 +0200
> @@ -47,11 +47,14 @@
>  initrx (int port)
>  {
>      int error;
> +    int i = 0;
>
>      if (port == 0)
>         port = afscallbackport;
>
> -    error = rx_Init (htons(port));
> +    while ((error = rx_Init (htons(port + i)))
> +          && i < 10)
> +       i++;
>      if (error)
>         arla_err (1, ADEBERROR, error, "rx_init");
>  }

I didn't check the source, so don't slap me too hard if this is a  
stupid question.

Is the port error the only error rx_Init can return?
You're trying to get another port (OK for just 10 times) on every  
init error.

If that's what was intended ... it's OK. ;-)

Horst
_______________________________________________
Arla-drinkers mailing list
Arla-drinkers@stacken.kth.se
https://lists.stacken.kth.se/mailman/listinfo/arla-drinkers

home help back first fref pref prev next nref lref last post