From cb354e5490115ba0fc737b72e957f9cba4798f22 Mon Sep 17 00:00:00 2001 From: Andrew Borodin Date: Mon, 8 Jan 2018 11:27:09 +0300 Subject: [PATCH] (vfs_file_handler_t::changed): change type from int to gboolean. Signed-off-by: Andrew Borodin --- lib/vfs/direntry.c | 6 +++--- lib/vfs/xdirentry.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/vfs/direntry.c b/lib/vfs/direntry.c index e7d308de4..c14bb6692 100644 --- a/lib/vfs/direntry.c +++ b/lib/vfs/direntry.c @@ -571,7 +571,7 @@ vfs_s_write (void *fh, const char *buffer, size_t count) if (FH->linear) vfs_die ("no writing to linear files, please"); - FH->changed = 1; + FH->changed = TRUE; if (FH->handle != -1) { ssize_t n; @@ -1231,7 +1231,7 @@ vfs_s_fullpath (struct vfs_class *me, struct vfs_s_inode *ino) void * vfs_s_open (const vfs_path_t * vpath, int flags, mode_t mode) { - int was_changed = 0; + gboolean was_changed = FALSE; vfs_file_handler_t *fh; struct vfs_s_super *super; const char *q; @@ -1292,7 +1292,7 @@ vfs_s_open (const vfs_path_t * vpath, int flags, mode_t mode) } g_free (dirname); g_free (name); - was_changed = 1; + was_changed = TRUE; } if (S_ISDIR (ino->st.st_mode)) diff --git a/lib/vfs/xdirentry.h b/lib/vfs/xdirentry.h index aaf79a2cb..4c9372140 100644 --- a/lib/vfs/xdirentry.h +++ b/lib/vfs/xdirentry.h @@ -106,7 +106,7 @@ typedef struct struct vfs_s_inode *ino; off_t pos; /* This is for module's use */ int handle; /* This is for module's use, but if != -1, will be mc_close()d */ - int changed; /* Did this file change? */ + gboolean changed; /* Did this file change? */ int linear; /* Is that file open with O_LINEAR? */ void *data; /* This is for filesystem-specific use */ } vfs_file_handler_t;