Windows NT 4.0 source code leak
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

36 lines
1008 B

/*** padmacro.h
*
* Macros used in converting from C6 symbols to C7. The majority of which
* are used to pad symbol and type records to be aligned on 4 byte
* bounderies.
*
*/
// Used to align on 4 byte bounderies
#define ALIGN4(x) ((x + 3) & ~3)
#define PAD4(x) (3 - ((x + 3) & 3))
// Add up to 3 pad bytes (loop is unrolled)
#define PADLOOP(count,sym)\
if( count-- ){\
*sym++ = 0;\
if( count-- ){\
*sym++ = 0;\
if( count-- ){\
*sym++ = 0;\
}\
}\
}
#ifdef NEVER
#define CALCNEWLEN(newlength,pad,StructType,varlength)\
{ \
register ushort usNTotal; \
\
usNTotal = sizeof (StructType) - 1 + varlength; \
newlength = ALIGN4 (usNTotal) - LNGTHSZ; \
pad = PAD4 (usNTotal); \
}
#endif