diff options
author | Roland McGrath <roland@gnu.org> | 2001-01-14 21:59:16 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 2001-01-14 21:59:16 +0000 |
commit | 3de1c4172465451ac4aaf4b4b9a568c76f2e0519 (patch) | |
tree | d1273c755c91dc49887d82bf436a4fd5509b2f1a | |
parent | f16d0273b577bdfdb8c47b65156b003eb221b8f3 (diff) |
2001-01-14 Roland McGrath <roland@frob.com>
* encode.c (too_big): New static function.
(store_std_leaf_encode): Use it to return EOVERFLOW if a run
does not fit in an off_t.
-rw-r--r-- | libstore/encode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libstore/encode.c b/libstore/encode.c index fd236486..7d119666 100644 --- a/libstore/encode.c +++ b/libstore/encode.c @@ -38,10 +38,10 @@ store_std_leaf_allocate_encoding (const struct store *store, return 0; } -/* The RPC protocol uses 32-bit ints, but store_offset_t is now 64 bits. */ +/* The RPC protocol uses 32-bit off_t's, but store_offset_t is now 64 bits. */ static inline int too_big (store_offset_t ofs) { - int o = (int) ofs; + off_t o = (off_t) ofs; return o < 0 || ((store_offset_t) o != ofs); } |