diff options
author | Simon Rettberg | 2024-04-23 14:29:13 +0200 |
---|---|---|
committer | Simon Rettberg | 2024-05-13 18:26:42 +0200 |
commit | b693a86fa87bdf001153d93e629425055a447897 (patch) | |
tree | 8435bc6e7c07a500d9afdbec9db2982fdc584fa3 | |
parent | [FUSE] Fix division by zero (diff) | |
download | dnbd3-b693a86fa87bdf001153d93e629425055a447897.tar.gz dnbd3-b693a86fa87bdf001153d93e629425055a447897.tar.xz dnbd3-b693a86fa87bdf001153d93e629425055a447897.zip |
[FUSE] Fix check for failed statsfile write
-rw-r--r-- | src/fuse/cowfile.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/fuse/cowfile.c b/src/fuse/cowfile.c index 4714402..b22d24a 100644 --- a/src/fuse/cowfile.c +++ b/src/fuse/cowfile.c @@ -479,7 +479,7 @@ static void updateCowStatsFile( uint64_t inQueue, uint64_t modified, uint64_t id ssize_t extra = MIN( 20, (ssize_t)sizeof(buffer) - len - 1 ); memset( buffer + len, '\n', extra ); lseek( cow.fdStats, 43, SEEK_SET ); - if ( write( cow.fdStats, buffer, len + extra ) != len ) { + if ( write( cow.fdStats, buffer, len + extra ) != len + extra ) { logadd( LOG_WARNING, "Could not update cow status file" ); } #ifdef COW_DUMP_BLOCK_UPLOADS |