Added threads supports [There are leaks =(]
Merge remote-tracking branch 'origin/master'