[CABMAN] Third addendum to 7afc888: Also use the the old code in the Trucate() method...
authorEric Kohl <eric.kohl@reactos.org>
Thu, 19 Sep 2019 13:36:18 +0000 (15:36 +0200)
committerEric Kohl <eric.kohl@reactos.org>
Thu, 19 Sep 2019 13:36:18 +0000 (15:36 +0200)
sdk/tools/cabman/CCFDATAStorage.cxx

index eecb6b5..b179079 100644 (file)
@@ -121,7 +121,11 @@ ULONG CCFDATAStorage::Destroy()
 ULONG CCFDATAStorage::Truncate()
 {
     fclose(FileHandle);
+#if defined(_WIN32)
     FileHandle = fopen(FullName, "w+b");
+#else
+    FileHandle = tmpfile();
+#endif
     if (FileHandle == NULL)
     {
         DPRINT(MID_TRACE, ("ERROR '%i'.\n", errno));