* timer.cc (getitimer): Don't create another local ret variable in
timer_gettime calling branch. Simplify conditional since timer_gettime always returns 0 or -1 anyway.
This commit is contained in:
parent
1cb1472404
commit
2196614e3d
|
@ -1,3 +1,9 @@
|
|||
2012-02-17 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* timer.cc (getitimer): Don't create another local ret variable in
|
||||
timer_gettime calling branch. Simplify conditional since timer_gettime
|
||||
always returns 0 or -1 anyway.
|
||||
|
||||
2012-02-17 Corinna Vinschen <corinna@vinschen.de>
|
||||
|
||||
* ntdll.h (struct _PEB): Add EnvironmentUpdateCount member.
|
||||
|
|
|
@ -423,10 +423,8 @@ getitimer (int which, struct itimerval *ovalue)
|
|||
else
|
||||
{
|
||||
struct itimerspec spec_ovalue;
|
||||
int ret = timer_gettime ((timer_t) &ttstart, &spec_ovalue);
|
||||
if (ret)
|
||||
ret = -1;
|
||||
else
|
||||
ret = timer_gettime ((timer_t) &ttstart, &spec_ovalue);
|
||||
if (!ret)
|
||||
{
|
||||
ovalue->it_interval.tv_sec = spec_ovalue.it_interval.tv_sec;
|
||||
ovalue->it_interval.tv_usec = spec_ovalue.it_interval.tv_nsec / 1000;
|
||||
|
|
Loading…
Reference in New Issue