Fixed memory leak
Merge branch 'master' into sailfishos
Added debuging information