fix: add checks to avoid invalid behavior

Related-To: NEO-9038
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2023-10-05 14:42:21 +00:00
committed by Compute-Runtime-Automation
parent 0c8a514349
commit ece03e6bbf
3 changed files with 7 additions and 2 deletions

View File

@@ -46,7 +46,9 @@ class Timer::TimerImpl {
}
TimerImpl &operator=(const TimerImpl &t) {
startTime = t.startTime;
if (this != &t) {
startTime = t.startTime;
}
return *this;
}