Removed blank lines at start/end of code blocks according to Google style guidelines whitespace/blank_line
Added whitespaces to comments according to Google style guidelines "whitespace/comments"
Moved "else" to same line as previous closing braces, according to Google style guidelines "whitespace/newline"
Added missing space before braces, according to Google style guidelines "whitespace/braces"
Ugly temporary fix for segfault in TelldusCenter