Fixed bugs in cp -r