summaryrefslogtreecommitdiff
path: root/rsync.h
diff options
context:
space:
mode:
authorWayne Davison <wayne@opencoder.net>2020-07-12 21:51:51 -0700
committerWayne Davison <wayne@opencoder.net>2020-07-12 22:45:01 -0700
commit91fff802b9513cf0ed616d3aea170d561f899fae (patch)
treea2ff6ab53afd4a6a3dee6fd28a4939e1a2cdcf04 /rsync.h
parent3c8ac20d63937e73aa8084679344c39916a93813 (diff)
downloadrsync-91fff802b9513cf0ed616d3aea170d561f899fae.tar.gz
Check for overflow the right way.
Diffstat (limited to 'rsync.h')
-rw-r--r--rsync.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/rsync.h b/rsync.h
index be4d8550..9942a705 100644
--- a/rsync.h
+++ b/rsync.h
@@ -711,6 +711,10 @@ struct ht_int64_node {
#define NAME_MAX 255
#endif
+#ifndef SIZE_MAX
+#define SIZE_MAX ((size_t)-1)
+#endif
+
#ifndef INADDR_NONE
#define INADDR_NONE 0xffffffff
#endif