fixed passing exit code