Code cleanup: Sensor read config cleanup

Ghost User requested to merge (removed):master into master

Changes:

  • Fix conditional memory leaks caused by g_return_if_fail()
  • Replace hard-coded constants with sizeof()

Merge request reports