Mail Archives: djgpp/1998/10/13/11:50:25
On Tue, 13 Oct 1998 rbarbosa AT my-dejanews DOT com wrote:
> My
> question is this, is there any way to dump a value (x) into (n) contiguous
> memory locations starting at a given address (a). I know memset(a, x, n)
> will do this, but memset() doesn't allow me to access protected space (like
> video RAM and such).
There's no such function in the library. Either write your own using
_farnspokeX family, or use memset to fill a buffer, then blit that
buffer to video RAM (or wherever you want it) with dosmemput.
You can also call __djgpp_nearptr_enable and then use memset with any
address, but this desables memory protection and won't work on NT, so
I don't recommend it.
Section 18.4 of the DJGPP FAQ list might provide additional insight on
related issues.
- Raw text -