38_netatmo: fix for invalid forecast data crashing FHEM

git-svn-id: https://svn.fhem.de/fhem/trunk@12266 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
markus-m 2016-10-03 16:42:29 +00:00
parent 0a277bfcee
commit 8c48f865d3
2 changed files with 3 additions and 0 deletions

View File

@ -1,5 +1,6 @@
# Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Add changes at the top of the list. Keep it in ASCII, and 80-char wide.
# Do not insert empty lines here, update check depends on it. # Do not insert empty lines here, update check depends on it.
- bugfix: 38_netatmo: fix for invalid forecast data crashing FHEM
- feature: 98_Hyperion: version check for hyperion server - feature: 98_Hyperion: version check for hyperion server
required min version of hyperion is now 1.03.2 required min version of hyperion is now 1.03.2
attr hyperionVersionCheck to disable version check attr hyperionVersionCheck to disable version check

View File

@ -2551,6 +2551,8 @@ netatmo_parseForecast($$)
foreach my $forecastdata ( @{$json->{body}{forecastDays}}) foreach my $forecastdata ( @{$json->{body}{forecastDays}})
{ {
next if(ref($forecastdata) ne "HASH");
if(defined($forecastdata->{rain})) if(defined($forecastdata->{rain}))
{ {
readingsBeginUpdate($hash); readingsBeginUpdate($hash);