Duplicated code with ProcessUtil.