updated execute_cmd() for use with wordexp_t.