aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2011-11-17 21:51:32 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2011-11-17 21:51:32 +0100
commit1dc80bae0b4c339553b8ee9fd8309c13f8c1f1d8 (patch)
tree77f07d440593017a6d4d79fbb994f445bf922add
parentf59a50ee3031c520fdb4183b98fd7b13b94be4f7 (diff)
downloadbusybox-w32-1dc80bae0b4c339553b8ee9fd8309c13f8c1f1d8.tar.gz
busybox-w32-1dc80bae0b4c339553b8ee9fd8309c13f8c1f1d8.tar.bz2
busybox-w32-1dc80bae0b4c339553b8ee9fd8309c13f8c1f1d8.zip
libbb.h: add check for bad off_t size detection
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--include/libbb.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 796351865..3f6fe47ed 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -245,6 +245,12 @@ typedef unsigned long uoff_t;
245#endif 245#endif
246/* scary. better ideas? (but do *test* them first!) */ 246/* scary. better ideas? (but do *test* them first!) */
247#define OFF_T_MAX ((off_t)~((off_t)1 << (sizeof(off_t)*8-1))) 247#define OFF_T_MAX ((off_t)~((off_t)1 << (sizeof(off_t)*8-1)))
248/* Users report bionic to use 32-bit off_t even if LARGEFILE support is requested.
249 * We misdetected that. Don't let it build:
250 */
251struct BUG_off_t_size_is_misdetected {
252 char BUG_off_t_size_is_misdetected[sizeof(off_t) == sizeof(uoff_t) ? 1 : -1];
253};
248 254
249/* Some useful definitions */ 255/* Some useful definitions */
250#undef FALSE 256#undef FALSE