linux thread sample