mirror of
https://github.com/VARCem/MiniVHD.git
synced 2026-09-24 07:45:12 +00:00
Let's pretend those sector bitmap macros weren't horribly broken
This commit is contained in:
@@ -6,9 +6,9 @@
|
||||
/* The following bit array macros adapted from
|
||||
http://www.mathcs.emory.edu/~cheung/Courses/255/Syllabus/1-C-intro/bit-array.html */
|
||||
|
||||
#define VHD_SETBIT(A,k) ( A[(k/8)] |= (1 << (k%8)) )
|
||||
#define VHD_CLEARBIT(A,k) ( A[(k/8)] &= ~(1 << (k%8)) )
|
||||
#define VHD_TESTBIT(A,k) ( A[(k/8)] & (1 << (k%8)) )
|
||||
#define VHD_SETBIT(A,k) ( A[(k/8)] |= (0x80 >> (k%8)) )
|
||||
#define VHD_CLEARBIT(A,k) ( A[(k/8)] &= ~(0x80 >> (k%8)) )
|
||||
#define VHD_TESTBIT(A,k) ( A[(k/8)] & (0x80 >> (k%8)) )
|
||||
|
||||
extern uint8_t VFT_CONECTIX_COOKIE[];
|
||||
extern uint8_t VFT_CREATOR[];
|
||||
|
||||
Reference in New Issue
Block a user