mirror of
https://github.com/status-im/macdylibbundler.git
synced 2025-02-20 06:38:09 +00:00
Don't attempt to copy files if from == to
This commit is contained in:
parent
3b64f6f518
commit
788339e038
@ -104,12 +104,12 @@ void copyFile(string from, string to)
|
||||
exit(1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
string override_permission = string(override ? "-f " : "-n ");
|
||||
|
||||
// copy file to local directory
|
||||
string command = string("cp ") + override_permission + from + string(" ") + to;
|
||||
if( systemp( command ) != 0 )
|
||||
if( from != to && systemp( command ) != 0 )
|
||||
{
|
||||
cerr << "\n\nError : An error occured while trying to copy file " << from << " to " << to << endl;
|
||||
exit(1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user