more perror cleanups