4 ms·
Ah.... very interesting. Now I know why [NSFileManager copyItemAtURL:...] failed to return an error when the file already existed, but only with a debugger atta
by jakobegger 9y ago
Ah.... very interesting. Now I know why [NSFileManager copyItemAtURL:...] failed to return an error when the file already existed, but only with a debugger attached. It presumably checks the errno after calling copyfile, and ignores the return value.
I remember debugging this issue -- it took me a few hours to find out why our test were using old data, until I found someone else reporting the issue [1], and implemented a workaround.
[1]: https://forums.developer.apple.com/thread/75927 https://forums.developer.apple.com/thread/75927