[quagga-dev 3570] Re: Bug in file: thread.c function: funcname_thread_add_timer_timeval

Paul Jakma paul at clubi.ie
Mon Aug 8 19:23:51 BST 2005

Hi Yossi,

On Tue, 2 Aug 2005, Yossi Boaron wrote:

> Hi
> In File thread.c function funcname_thread_add_timer_timeval
> In this function there's a call to the function timeval_adjust,the 
> parameter to timeval_adjust is transferred by value , and hence 
> this function will not change the parameter value.

Which version of Quagga?

>  timer_now.tv_sec += time_relative->tv_sec;
>  timer_now.tv_usec += time_relative->tv_usec;
>  timeval_adjust (timer_now);

The current code says:

   alarm_time.tv_sec = recent_time.tv_sec + time_relative->tv_sec;
   alarm_time.tv_usec = recent_time.tv_usec + time_relative->tv_usec;
   thread->u.sands = timeval_adjust(alarm_time);

Paul Jakma	paul at clubi.ie	paul at jakma.org	Key ID: 64A2FF6A
A verbal contract isn't worth the paper it's written on.
 		-- Samuel Goldwyn

More information about the Quagga-dev mailing list