Skip to content

Commit b11a617

Browse files
Lei Jinyhchiang
authored andcommitted
dummy var to suppress compiler warning/error
Summary: Revmoed this in D25641, causing compiler complain. put it back Test Plan: make release Reviewers: igor, yhchiang, rven, sdong Reviewed By: sdong Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D27891
1 parent f96bb67 commit b11a617

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

util/env_posix.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -738,7 +738,8 @@ class PosixWritableFile : public WritableFile {
738738
// trim the extra space preallocated at the end of the file
739739
// NOTE(ljin): we probably don't want to surface failure as an IOError,
740740
// but it will be nice to log these errors.
741-
ftruncate(fd_, filesize_);
741+
int dummy __attribute__((unused));
742+
dummy = ftruncate(fd_, filesize_);
742743
#ifdef ROCKSDB_FALLOCATE_PRESENT
743744
// in some file systems, ftruncate only trims trailing space if the
744745
// new file size is smaller than the current size. Calling fallocate

0 commit comments

Comments
 (0)