Hi, On Thu, 10 Jan 2008, Jim Meyering wrote: > Johannes Schindelin <Johannes.Schindelin@xxxxxx> wrote: > > > I recently read an article which got me thinking about close(). The > > author maintained that many mistakes are done by being overzealously > > defensive; die()ing in case of a close() failure (when open() > > succeeded!) might be just wrong. > > No. Whether open succeeded is a separate matter. Avoiding an unreported > write (or close-writable-fd) failure is not being "overzealously > defensive." Are you aware what this code does? It writes a ".keep" file. Whose purpose is to _exist_, and whose purpose is fulfilled, even if the write or the push-back did not succeed. I could not care less what the manual says. What is important is if the defensive programming is done mindlessly, and therefore can fail so not gracefully. Ciao, Dscho - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html