diff options
Diffstat (limited to 'source3/libads')
-rw-r--r-- | source3/libads/dns.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/source3/libads/dns.c b/source3/libads/dns.c index 570f9583f0..558c7f75ba 100644 --- a/source3/libads/dns.c +++ b/source3/libads/dns.c @@ -245,17 +245,11 @@ static BOOL ads_dns_parse_rr_ns( TALLOC_CTX *ctx, uint8 *start, uint8 *end, static int dnssrvcmp( struct dns_rr_srv *a, struct dns_rr_srv *b ) { - BOOL init = False; - - if ( !init ) { - srand( (uint32)time(NULL) ); - } - if ( a->priority == b->priority ) { /* randomize entries with an equal weight and priority */ if ( a->weight == b->weight ) - return rand() % 2 ? -1 : 1; + return 0; /* higher weights should be sorted lower */ if ( a->weight > b->weight ) |