Skip to content

Commit 66c00c1

Browse files
committed
Avoid possible unnecessary time conversion.
1 parent c808a1a commit 66c00c1

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
@@ -261,7 +261,7 @@ class timeoutTemplate
261261
timeType current = TimePolicyT::time();
262262
if(checkExpired(current))
263263
{
264-
unsigned long n = (current - _start) / _timeout; //how many _timeouts periods have elapsed, will usually be 1 (current - _start >= _timeout)
264+
timeType n = (current - _start) / _timeout; //how many _timeouts periods have elapsed, will usually be 1 (current - _start >= _timeout)
265265
_start += n * _timeout;
266266
return true;
267267
}

0 commit comments

Comments
 (0)