From 4aca87515a5083ae0e31ce3177189fd43b6d05ac Mon Sep 17 00:00:00 2001 From: Andreas Baumann Date: Sat, 3 Jan 2015 13:58:15 +0100 Subject: patch to Vanilla Tomato 1.28 --- .../linux/scripts/squashfs/lzma/C/Common/Defs.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 release/src/linux/linux/scripts/squashfs/lzma/C/Common/Defs.h (limited to 'release/src/linux/linux/scripts/squashfs/lzma/C/Common/Defs.h') diff --git a/release/src/linux/linux/scripts/squashfs/lzma/C/Common/Defs.h b/release/src/linux/linux/scripts/squashfs/lzma/C/Common/Defs.h new file mode 100644 index 00000000..69b8ecea --- /dev/null +++ b/release/src/linux/linux/scripts/squashfs/lzma/C/Common/Defs.h @@ -0,0 +1,20 @@ +// Common/Defs.h + +#ifndef __COMMON_DEFS_H +#define __COMMON_DEFS_H + +template inline T MyMin(T a, T b) + { return a < b ? a : b; } +template inline T MyMax(T a, T b) + { return a > b ? a : b; } + +template inline int MyCompare(T a, T b) + { return a < b ? -1 : (a == b ? 0 : 1); } + +inline int BoolToInt(bool value) + { return (value ? 1: 0); } + +inline bool IntToBool(int value) + { return (value != 0); } + +#endif -- cgit v1.2.3-54-g00ecf