/*
- * Copyright 2013 Facebook, Inc.
+ * Copyright 2015 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
return r;
}
-inline void incr(ssize_t n) { }
+inline void incr(ssize_t /* n */) {}
inline void incr(ssize_t n, off_t& offset) { offset += n; }
// Wrap call to read/pread/write/pwrite(fd, buf, count, offset?) to retry on
template <class F, class... Offset>
ssize_t wrapvFull(F f, int fd, iovec* iov, int count, Offset... offset) {
ssize_t totalBytes = 0;
- ssize_t r;
+ size_t r;
do {
r = f(fd, iov, count, offset...);
- if (r == -1) {
+ if (r == (size_t)-1) {
if (errno == EINTR) {
continue;
}
}} // namespaces
#endif /* FOLLY_DETAIL_FILEUTILDETAIL_H_ */
-