make exitcode dynamic