On 07/06/12 19:46, Gert Doering wrote:
> Hi,
> 
> Solaris buildslave failed to test, because "--dev tun" did not work
> if tun0 was already in use (didn't hunt to tun1).
> 
> Fixed, tested on OpenSolaris 10 / i386 - but the code is straightforward, 
> so it should work on "standard Solaris" and "sparc" as well.  Managed to
> get it to hunt to tun2 just fine, and then ran out of possible OpenVPN
> targets :-) but if it works for tun0, tun1, tun2 there is no reason why
> it shouldn't work for tun63. 
> 
> The moving around of the open() calls is purely cosmetic - I wanted to
> have all code that relates to tun device unit number in one block, not
> "first parse device name, then open unrelated stuff, then try to use
> that just-parsed device and the resulting 'ptr' variable".

ACK.  Applied to master branch.

commit 21ae2ec2b963e33e1b48b6cf9069e774b3f656b1
Author: Gert Doering <g...@greenie.muc.de>
List-Post: openvpn-devel@lists.sourceforge.net
Date:   Thu Jun 7 17:38:17 2012 +0200

    Implement search for "first free" tun/tap device on Solaris
    
    Without this patch, Solaris will do "--dev tun3" just fine, but "--dev tun"
    will either use "tun0" if that is available, or fail.  With the patch, the
    first available device is searched if "--dev tun" or "--dev tap" (without
    a number) is specified.
    
    Signed-off-by: Gert Doering <g...@greenie.muc.de>
    Acked-by: David Sommerseth <dav...@redhat.com>
    Message-Id: 20120607174638.gw1...@greenie.muc.de
    URL: http://article.gmane.org/gmane.network.openvpn.devel/6705
    Signed-off-by: David Sommerseth <dav...@redhat.com>

 src/openvpn/tun.c |   40 ++++++++++++++++++++++++++++++++--------
 1 files changed, 32 insertions(+), 8 deletions(-)


kind regards,

David Sommerseth

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to