sot / starcheck

BSD 3-Clause "New" or "Revised" License
3 stars 0 forks source link

Fix benign dither bug (Use of uninitialized value) #393

Closed jeanconn closed 2 years ago

jeanconn commented 2 years ago

Description

Fix benign dither bug (Use of uninitialized value)

https://github.com/sot/starcheck/pull/390 introduced this tiny bug by checking for the empty string instead of a defined value. We could use the empty string and change the check or update the check to use defined(). This PR uses defined().

Fixes warning:

Use of uninitialized value $dither_error in string ne at ./starcheck/src/starcheck.pl line 280.

Interface impacts

Testing

Unit tests

Functional tests

Ran with and without this change, and with the changes in this PR the warning

Use of uninitialized value $dither_error in string ne at ./starcheck/src/starcheck.pl line 280.

is not present on a load without dither issues. I ran on an old AUG2322 with dither mismatch with history and the dither warning printing at console and in starcheck html output is preserved and correct.