Changeset 1052

Show
Ignore:
Timestamp:
05/19/07 14:30:43 (1 year ago)
Author:
ahu
Message:

fix 1<<31 issue with intel c compiler, noted by darix

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/pdns/pdns/communicator.hh

    r681 r1052  
    11/* 
    22    PowerDNS Versatile Database Driven Nameserver 
    3     Copyright (C) 2002  PowerDNS.COM BV 
     3    Copyright (C) 2002-2007  PowerDNS.COM BV 
    44 
    55    This program is free software; you can redistribute it and/or modify 
     
    2525#include <queue> 
    2626#include <list> 
     27#include <limits> 
    2728 
    2829#ifndef WIN32 
     
    9596  time_t earliest() 
    9697  { 
    97     time_t early=(1<<31)-1; // y2038 problem lurking here :-) 
     98    time_t early=numeric_limits<time_t>::max() - 1;  
    9899    for(d_nqueue_t::const_iterator i=d_nqueue.begin();i!=d_nqueue.end();++i)  
    99100      early=min(early,i->next);