make TIMEOUT more reliable
if config value is missing, use default one
Merge pull request #1 from spitfire05/devel

merging latest changes into master