Seek to 0 before writing to /dev/vga.
This commit is contained in:
parent
4f60d028ef
commit
7e05129023
|
@ -57,7 +57,9 @@ void Clear()
|
|||
|
||||
bool FlushVGA()
|
||||
{
|
||||
return writeall(vgafd, frame, sizeof(frame)) < sizeof(frame);
|
||||
if ( lseek(vgafd, 0, SEEK_SET) < 0)
|
||||
return false;
|
||||
return writeall(vgafd, frame, sizeof(frame)) == sizeof(frame);
|
||||
}
|
||||
|
||||
int Init()
|
||||
|
|
|
@ -70,7 +70,9 @@ unsigned soundleft;
|
|||
|
||||
bool FlushVGA()
|
||||
{
|
||||
return writeall(vgafd, frame, sizeof(frame)) < sizeof(frame);
|
||||
if ( lseek(vgafd, 0, SEEK_SET) < 0)
|
||||
return false;
|
||||
return writeall(vgafd, frame, sizeof(frame)) == sizeof(frame);
|
||||
}
|
||||
|
||||
int Init()
|
||||
|
|
|
@ -95,7 +95,9 @@ void Reset()
|
|||
|
||||
bool FlushVGA()
|
||||
{
|
||||
return writeall(vgafd, frame, sizeof(frame)) < sizeof(frame);
|
||||
if ( lseek(vgafd, 0, SEEK_SET) < 0)
|
||||
return false;
|
||||
return writeall(vgafd, frame, sizeof(frame)) == sizeof(frame);
|
||||
}
|
||||
|
||||
int Init()
|
||||
|
|
Loading…
Reference in New Issue