"Fossies" - the Fresh Open Source Software Archive

Member "unrar/rardefs.hpp" (4 May 2022, 758 Bytes) of package /linux/misc/unrarsrc-6.1.7.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "rardefs.hpp" see the Fossies "Dox" file reference documentation.

    1 #ifndef _RAR_DEFS_
    2 #define _RAR_DEFS_
    3 
    4 #define  Min(x,y) (((x)<(y)) ? (x):(y))
    5 #define  Max(x,y) (((x)>(y)) ? (x):(y))
    6 
    7 // Universal replacement of abs function.
    8 #define  Abs(x) (((x)<0) ? -(x):(x))
    9 
   10 #define  ASIZE(x) (sizeof(x)/sizeof(x[0]))
   11 
   12 // MAXPASSWORD is expected to be multiple of CRYPTPROTECTMEMORY_BLOCK_SIZE (16)
   13 // for CryptProtectMemory in SecPassword.
   14 #define  MAXPASSWORD       128
   15 
   16 #define  MAXSFXSIZE        0x200000
   17 
   18 #define  MAXCMTSIZE        0x40000
   19 
   20 #define  DefSFXName        L"default.sfx"
   21 #define  DefSortListName   L"rarfiles.lst"
   22 
   23 
   24 #ifndef SFX_MODULE
   25 #define USE_QOPEN
   26 #endif
   27 
   28 // Produce the value, which is equal or larger than 'v' and aligned to 'a'.
   29 #define ALIGN_VALUE(v,a) (size_t(v) + ( (~size_t(v) + 1) & (a - 1) ) )
   30 
   31 #endif