bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unlink failure on abort


From: Orgad Shaneh
Subject: Re: Unlink failure on abort
Date: Sun, 18 Jun 2017 17:51:59 +0300

On Sun, Jun 18, 2017 at 2:42 PM, David Boyce <address@hidden> wrote:
In the event this patch is used: I think the interleaved-ifdef style is hard to read and best avoided. How about either separating the Windows and "other" clauses at the top level or something like this (with suitable comment):

+      for (e = 0; e < 10; ++e)
+        {
+          status = unlink (file->name);
+#ifdef WINDOWS32
+          if (status == 0 || errno == ENOENT)
+            break;
+          Sleep(5);
+#else
+          break;
+        }
+#endif

Yes, this looks a bit cleaner. But the #endif should be one line above of course :)

- Orgad

reply via email to

[Prev in Thread] Current Thread [Next in Thread]