blob: ac1b85c3e05cab3a2425269435777ad43bca396b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
/* -*-C-*- getbmap.h */
/*-->getbmap*/
/**********************************************************************/
/****************************** getbmap *******************************/
/**********************************************************************/
void
getbmap() /* allocate bitmap array */
{
#if SEGMEM
register UNSIGN16 y;
if (bitmap[0] == (UNSIGN32*)NULL)
{
for (y = 0; y < (UNSIGN16)YBIT; ++y)
{
bitmap[y] = (UNSIGN32*)MALLOC( (unsigned)((XBIT) * \
sizeof(UNSIGN32)) );
if (bitmap[y] == (UNSIGN32*)NULL)
(void)fatal(
"getbmap(): Cannot allocate space for page image bitmap");
}
}
#else /* NOT SEGMEM */
if (bitmap == (UNSIGN32*)NULL)
{
bitmap =
(UNSIGN32*)MALLOC(((UNSIGN32)(XBIT))*((UNSIGN32)(YBIT))*sizeof(UNSIGN32));
if (bitmap == (UNSIGN32*)NULL)
(void)fatal(
"getbmap(): Cannot allocate space for page image bitmap");
}
#endif /* SEGMEM */
}
|