Changeset: da082f89abfc for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=da082f89abfc
Modified Files:
        gdk/gdk_storage.c
Branch: Jun2016
Log Message:

Must not ignore return value of ftruncate.


diffs (13 lines):

diff --git a/gdk/gdk_storage.c b/gdk/gdk_storage.c
--- a/gdk/gdk_storage.c
+++ b/gdk/gdk_storage.c
@@ -353,7 +353,8 @@ GDKextendf(int fd, size_t size, const ch
                        /* extending failed, try to reduce file size
                         * back to original */
                        int err = errno;
-                       (void) ftruncate(fd, stb.st_size);
+                       if (ftruncate(fd, stb.st_size))
+                               perror("ftruncate");
                        errno = err; /* restore for error message */
                        GDKsyserror("GDKextendf: could not extend file\n");
                }
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to