[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r19691 - gnunet-gtk/src/fs
From: |
gnunet |
Subject: |
[GNUnet-SVN] r19691 - gnunet-gtk/src/fs |
Date: |
Sat, 4 Feb 2012 22:28:14 +0100 |
Author: grothoff
Date: 2012-02-04 22:28:14 +0100 (Sat, 04 Feb 2012)
New Revision: 19691
Modified:
gnunet-gtk/src/fs/gnunet-fs-gtk_common.c
Log:
-do not try to mmap empty file
Modified: gnunet-gtk/src/fs/gnunet-fs-gtk_common.c
===================================================================
--- gnunet-gtk/src/fs/gnunet-fs-gtk_common.c 2012-02-04 21:18:27 UTC (rev
19690)
+++ gnunet-gtk/src/fs/gnunet-fs-gtk_common.c 2012-02-04 21:28:14 UTC (rev
19691)
@@ -210,6 +210,11 @@
GNUNET_break (0);
return GNUNET_SYSERR;
}
+ if (0 == fsize)
+ {
+ /* empty file, cannot be a directory */
+ return GNUNET_SYSERR;
+ }
if (NULL == (fh = GNUNET_DISK_file_open (filename, GNUNET_DISK_OPEN_READ,
GNUNET_DISK_PERM_NONE)))
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r19691 - gnunet-gtk/src/fs,
gnunet <=