include <pthreand.h> for fix pthead bug of segmentation fault on linux 64 bit
optizimed pthread function return value state