Avoid null dereference

Found via clang-tidy.
This commit is contained in:
Andrew Gaul 2019-07-12 18:40:24 -07:00
parent 50d13255e4
commit eb597289cb

View File

@ -893,8 +893,9 @@ static int s3fs_getattr(const char* _path, struct stat* stbuf)
} }
stbuf->st_blksize = 4096; stbuf->st_blksize = 4096;
stbuf->st_blocks = get_blocks(stbuf->st_size); stbuf->st_blocks = get_blocks(stbuf->st_size);
S3FS_PRN_DBG("[path=%s] uid=%u, gid=%u, mode=%04o", path, (unsigned int)(stbuf->st_uid), (unsigned int)(stbuf->st_gid), stbuf->st_mode);
} }
S3FS_PRN_DBG("[path=%s] uid=%u, gid=%u, mode=%04o", path, (unsigned int)(stbuf->st_uid), (unsigned int)(stbuf->st_gid), stbuf->st_mode);
S3FS_MALLOCTRIM(0); S3FS_MALLOCTRIM(0);
return result; return result;