X-Git-Url: https://git.pterodactylus.net/?p=ccp.git;a=blobdiff_plain;f=ccp.c;h=a83d2e82c108984b262334a3039257383128f244;hp=6a40186668df2eb66db0cd087395ac31c5babc3d;hb=HEAD;hpb=41d281b9fd8f2629103b3867e6277cd1ee8a4b4b diff --git a/ccp.c b/ccp.c index 6a40186..a83d2e8 100644 --- a/ccp.c +++ b/ccp.c @@ -149,6 +149,7 @@ int copyFileToFile(char* sourceFile, char* destFile) { } toWrite -= written; } while (toWrite); + fsync(fileno(outputFile)); ftime(&endTime); writtenTotal += written; progress = (double) writtenTotal / fileSize;