pixmirror: chdir before removing empty dirs