summaryrefslogtreecommitdiff
path: root/libcaja-private/caja-file.c
diff options
context:
space:
mode:
authorScott Balneaves <[email protected]>2013-04-17 09:54:23 -0500
committerScott Balneaves <[email protected]>2013-04-17 09:54:23 -0500
commit2ba883533e92099322f595085d7ce4941226913f (patch)
treeae5a848b2ef6362214202486cf18ec7af1abd05b /libcaja-private/caja-file.c
parentfb44f5ae12331d8ebfd0d6af6c091bced2fa3464 (diff)
downloadcaja-2ba883533e92099322f595085d7ce4941226913f.tar.bz2
caja-2ba883533e92099322f595085d7ce4941226913f.tar.xz
Possible fix for Issue #111
Diffstat (limited to 'libcaja-private/caja-file.c')
-rw-r--r--libcaja-private/caja-file.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libcaja-private/caja-file.c b/libcaja-private/caja-file.c
index 1958fafc..6c252e3b 100644
--- a/libcaja-private/caja-file.c
+++ b/libcaja-private/caja-file.c
@@ -7158,6 +7158,10 @@ caja_file_is_binary (CajaFile *file)
*/
fp = g_fopen (g_file_get_path (caja_file_get_location (file)), "r");
+ if (fp == NULL)
+ {
+ return FALSE;
+ }
for (i = 0; i < 4096; i++) {
c = fgetc(fp);
if (c == EOF) {