Work around wrong value obtained from registry