Fixed Bug at registryreading