X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=daemon%2Ffile.c;h=3f07ffc12e2288f2fb52fc922f1fec16917e00fd;hb=b96fb7eb3aa0ac67957ed15a7dd22bc7399cad44;hp=0eef0c09c29583d8daa938e27455dc9cd0694b98;hpb=56bef498f46ac3dd580f4bde3c8f3ed2fe688826;p=libguestfs.git diff --git a/daemon/file.c b/daemon/file.c index 0eef0c0..3f07ffc 100644 --- a/daemon/file.c +++ b/daemon/file.c @@ -58,7 +58,11 @@ do_touch (char *path) return -1; } - close (fd); + if (close (fd) == -1) { + reply_with_perror ("close: %s", path); + return -1; + } + return 0; }