Annotation of 43BSD/contrib/X/Xlib/XPutBackEvent.c, revision 1.1.1.1

1.1       root        1: #include <X/mit-copyright.h>
                      2: 
                      3: /* Copyright   Massachusetts Institute of Technology  1985 */
                      4: /* $Header: XPutBackEvent.c,v 10.5 86/02/01 15:38:34 tony Rel $ */
                      5: /* XPutBackEvent puts an event back at the head of the queue. */
                      6: 
                      7: #include "XlibInternal.h"
                      8: 
                      9: extern _QEvent *_qfree;
                     10: 
                     11: XPutBackEvent (event)
                     12:        register XEvent *event;
                     13:        {
                     14:        register _QEvent *qelt;
                     15:        register Display *dpy = _XlibCurrentDisplay;
                     16:        if (!_qfree) {
                     17:            _qfree = (_QEvent *) malloc (sizeof (_QEvent));
                     18:            _qfree->next = NULL;
                     19:            }
                     20:        qelt = _qfree;
                     21:        _qfree = qelt->next;
                     22:        qelt->next = dpy->head;
                     23:        qelt->event = *event;
                     24:        dpy->head = qelt;
                     25:        if (dpy->tail == NULL)
                     26:            dpy->tail = qelt;
                     27:        dpy->qlen++;
                     28:        }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.