We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello, I get a warning in RTCZero.cpp line 96:26, without having a bug.
'oldTime.RTC_MODE2_CLOCK_Type::reg' may be used uninitialized in this function [-Wmaybe-uninitialized]
line 96:26 :
if ((!resetTime) && (validTime) && (oldTime.reg != 0L)) { RTC->MODE2.CLOCK.reg = oldTime.reg; }
Looking at the code, I guess the problem is here, there no "else" or an initialization to define "oldTime.reg".
if ((!resetTime) && (PM->RCAUSE.reg & (PM_RCAUSE_SYST | PM_RCAUSE_WDT | PM_RCAUSE_EXT))) { if (RTC->MODE2.CTRL.reg & RTC_MODE2_CTRL_MODE_CLOCK) { validTime = true; oldTime.reg = RTC->MODE2.CLOCK.reg; } }
Thanks a lot.
The text was updated successfully, but these errors were encountered:
Add getAlarmEpoch() method (arduino-libraries#60)
06db30f
Fix warning on compiling with oldTime.RTC_MODE2_CLOCK_Type::reg (arduino-libraries#67)
Successfully merging a pull request may close this issue.
Hello,
I get a warning in RTCZero.cpp line 96:26, without having a bug.
line 96:26 :
Looking at the code, I guess the problem is here, there no "else" or an initialization to define "oldTime.reg".
Thanks a lot.
The text was updated successfully, but these errors were encountered: