examples/kernel: fix warnings issued by Clang

Fix some "unused variable" and "used before set" warnings.
dfs: assert the path is not null in dfs_filesystem_lookup

Clang complains about "Null pointer argument in call to string
comparison function". So assert on it.
pthreads: remove some useless variables
finsh: add check on converting octal numbers

The digit in octal numbers should with in 0~7. Check on it in
token_proc_number. This issue is found by Clang.
msh: remove usless ptr set

The ptr is set in the following code. So remove the first one.
minilibc: no double braces in if statement
Merge pull request #262 from grissiom/misc-fix

Misc fix