[vhffs-dev] [552] OOops previous commit introduced a new bug (unicity check problem).

[ Thread Index | Date Index | More vhffs.org/vhffs-dev Archives ]


Revision: 552
Author:   beuss
Date:     2007-04-10 12:05:15 +0000 (Tue, 10 Apr 2007)

Log Message:
-----------
OOops previous commit introduced a new bug (unicity check problem).

Modified Paths:
--------------
    branches/vhffs_4.1/vhffs-api/src/Vhffs/Services/DNS.pm


Modified: branches/vhffs_4.1/vhffs-api/src/Vhffs/Services/DNS.pm
===================================================================
--- branches/vhffs_4.1/vhffs-api/src/Vhffs/Services/DNS.pm	2007-04-10 11:53:11 UTC (rev 551)
+++ branches/vhffs_4.1/vhffs-api/src/Vhffs/Services/DNS.pm	2007-04-10 12:05:15 UTC (rev 552)
@@ -432,9 +432,9 @@
     my ( $self , $name , $ip , $ttl ) = @_;
     
     $ttl = 900 if ( ! defined $ttl );
-    return -1 if ( $self->name_exists( $name ) != 0 );
     return -1 if( ! ($name =~ /^[a-z0-9\-]+|\*$/ ) );
     $name = '' if( $name eq 'default' );
+    return -1 if ( $self->name_exists( $name ) != 0 );
 
     if( ! defined $ip ) {
         my $config = $self->{'main'}->get_config;	


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/