Skip to content

Commit 1d68d42

Browse files
committed
Avoid possible unnecessary time conversion.
1 parent 8a9d25b commit 1d68d42

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cores/esp8266/PolledTimeout.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ class timeoutTemplate
260260
timeType current = TimePolicyT::time();
261261
if(checkExpired(current))
262262
{
263-
unsigned long n = (current - _start) / _timeout; //how many _timeouts periods have elapsed, will usually be 1 (current - _start >= _timeout)
263+
timeType n = (current - _start) / _timeout; //how many _timeouts periods have elapsed, will usually be 1 (current - _start >= _timeout)
264264
_start += n * _timeout;
265265
return true;
266266
}

0 commit comments

Comments
 (0)