bug fix #155: check input length.
Merge branch 'master' of https://github.com/jobinrefer/dev