summaryrefslogtreecommitdiff
path: root/sysspec.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysspec.c')
-rw-r--r--sysspec.c48
1 files changed, 24 insertions, 24 deletions
diff --git a/sysspec.c b/sysspec.c
index a97010d..ab6dc88 100644
--- a/sysspec.c
+++ b/sysspec.c
@@ -60,7 +60,7 @@
** Currently, mem_array[][] is only used if you use malloc;
** it is not used for the 16-bit DOS and MAC versions.
*/
-farvoid *AllocateMemory(unsigned long nbytes, /* # of bytes to alloc */
+void *AllocateMemory(unsigned long nbytes, /* # of bytes to alloc */
int *errorcode) /* Returned error code */
{
#ifdef DOS16MEM
@@ -88,14 +88,14 @@ intdos(&registers,&registers); /* Call DOS */
if(registers.x.cflag)
{ printf("error: %d Lgst: %d\n",registers.x.ax,registers.x.bx);
*errorcode=ERROR_MEMORY;
- return((farvoid *)NULL);
+ return((void *)NULL);
}
/*
-** Create a farvoid pointer to return.
+** Create a void pointer to return.
*/
*errorcode=0;
-return((farvoid *)MK_FP(registers.x.ax,0));
+return((void *)MK_FP(registers.x.ax,0));
#endif
@@ -103,9 +103,9 @@ return((farvoid *)MK_FP(registers.x.ax,0));
/*
** For MAC CodeWarrior, we'll use the MacOS NewPtr call
*/
-farvoid *returnval;
-returnval=(farvoid *)NewPtr((Size)nbytes);
-if(returnval==(farvoid *)NULL)
+void *returnval;
+returnval=(void *)NewPtr((Size)nbytes);
+if(returnval==(void *)NULL)
*errorcode=ERROR_MEMORY;
else
*errorcode=0;
@@ -118,12 +118,12 @@ return(returnval);
** that you use a 32-bit compiler which treats size_t as
** a 4-byte entity.
*/
-farvoid *returnval; /* Return value */
+void *returnval; /* Return value */
ulong true_addr; /* True address */
ulong adj_addr; /* Adjusted address */
-returnval=(farvoid *)malloc((size_t)(nbytes+2L*(long)global_align));
-if(returnval==(farvoid *)NULL)
+returnval=(void *)malloc((size_t)(nbytes+2L*(long)global_align));
+if(returnval==(void *)NULL)
*errorcode=ERROR_MEMORY;
else
*errorcode=0;
@@ -163,7 +163,7 @@ return(returnval);
** block passed in is freed. Should an error occur,
** that error is returned in errorcode.
*/
-void FreeMemory(farvoid *mempointer, /* Pointer to memory block */
+void FreeMemory(void *mempointer, /* Pointer to memory block */
int *errorcode)
{
#ifdef DOS16MEM
@@ -176,7 +176,7 @@ union REGS registers;
struct SREGS sregisters;
/*
-** First get the segment/offset of the farvoid pointer.
+** First get the segment/offset of the void pointer.
*/
segment=FP_SEG(mempointer);
offset=FP_OFF(mempointer);
@@ -238,8 +238,8 @@ return;
** In most cases, this is just a memmove operation.
** But, not in DOS....noooo....
*/
-void MoveMemory( farvoid *destination, /* Destination address */
- farvoid *source, /* Source address */
+void MoveMemory( void *destination, /* Destination address */
+ void *source, /* Source address */
unsigned long nbytes)
{
@@ -262,8 +262,8 @@ memmove(destination, source, nbytes);
** Performs the same function as memmove for DOS when
** the arrays are defined with far pointers.
*/
-void FarDOSmemmove(farvoid *destination, /* Destination pointer */
- farvoid *source, /* Source pointer */
+void FarDOSmemmove(void *destination, /* Destination pointer */
+ void *source, /* Source pointer */
unsigned long nbytes) /* # of bytes to move */
{
unsigned char huge *uchsource; /* Temp source */
@@ -293,8 +293,8 @@ if(saddr > daddr)
** We'll move 65535 bytes at a time.
*/
while(nbytes>=65535L)
- { _fmemmove((farvoid *)uchdest,
- (farvoid *)uchsource,
+ { _fmemmove((void *)uchdest,
+ (void *)uchsource,
(size_t) 65535);
uchsource+=65535; /* Advance pointers */
uchdest+=65535;
@@ -305,8 +305,8 @@ if(saddr > daddr)
** Move remaining bytes
*/
if(nbytes!=0L)
- _fmemmove((farvoid *)uchdest,
- (farvoid *)uchsource,
+ _fmemmove((void *)uchdest,
+ (void *)uchsource,
(size_t)(nbytes & 0xFFFF));
}
@@ -329,8 +329,8 @@ else
{
uchsource-=65535;
uchdest-=65535;
- _fmemmove((farvoid *)uchdest,
- (farvoid *)uchsource,
+ _fmemmove((void *)uchdest,
+ (void *)uchsource,
(size_t) 65535);
nbytes-=65535;
}
@@ -341,8 +341,8 @@ else
if(nbytes!=0L)
{ uchsource-=nbytes;
uchdest-=nbytes;
- _fmemmove((farvoid *)uchdest,
- (farvoid *)uchsource,
+ _fmemmove((void *)uchdest,
+ (void *)uchsource,
(size_t)(nbytes & 0xFFFF));
}
}