1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-04 11:00:45 -08:00

Moving some common definitions to eventcom.h from event.h.

Fixing the types of EventCode etc. to use narrower types to compress things on 64-bit architectures.
Fixing some warnings.

Copied from Perforce
 Change: 179015
 ServerID: perforce.ravenbrook.com
This commit is contained in:
Richard Brooksby 2012-08-22 08:41:42 +01:00
parent 5e96e53da6
commit 30283c6f11
4 changed files with 44 additions and 43 deletions

View file

@ -46,11 +46,15 @@ Word EventKindControl; /* Bit set used to control output. */
Res EventFlush(void)
{
Res res;
size_t size;
AVER(eventInited);
res = (Res)mps_io_write(eventIO, (void *)eventBuffer,
EventNext - eventBuffer);
AVER(eventBuffer <= EventNext);
AVER(EventNext <= eventBuffer + EventBufferSIZE);
size = (size_t)(EventNext - eventBuffer);
res = (Res)mps_io_write(eventIO, (void *)eventBuffer, size);
EventNext = eventBuffer;
if (res != ResOK) return res;