[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r36837 - libmicrohttpd/src/examples
From: |
gnunet |
Subject: |
[GNUnet-SVN] r36837 - libmicrohttpd/src/examples |
Date: |
Mon, 18 Jan 2016 22:41:49 +0100 |
Author: grothoff
Date: 2016-01-18 22:41:49 +0100 (Mon, 18 Jan 2016)
New Revision: 36837
Modified:
libmicrohttpd/src/examples/demo_https.c
Log:
-check rval before fstat'ing
Modified: libmicrohttpd/src/examples/demo_https.c
===================================================================
--- libmicrohttpd/src/examples/demo_https.c 2016-01-18 21:39:09 UTC (rev
36836)
+++ libmicrohttpd/src/examples/demo_https.c 2016-01-18 21:41:49 UTC (rev
36837)
@@ -699,8 +699,9 @@
('/' != url[1]) )
{
fd = open (&url[1], O_RDONLY);
- if ( (0 != fstat (fd, &buf)) ||
- (! S_ISREG (buf.st_mode)) )
+ if ( (-1 != fd) &&
+ ( (0 != fstat (fd, &buf)) ||
+ (! S_ISREG (buf.st_mode)) ) )
{
(void) close (fd);
fd = -1;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r36837 - libmicrohttpd/src/examples,
gnunet <=