| 27 | } |
| 28 | |
| 29 | event_emul *StartEvent() |
| 30 | { |
| 31 | event_emul *ret; |
| 32 | ret = (event_emul *)malloc(sizeof(event_emul)); |
| 33 | ret->mutex = SDL_CreateMutex(); |
| 34 | if (ret->mutex == NULL) { |
| 35 | ErrSdl(); |
| 36 | } |
| 37 | ret->cond = SDL_CreateCond(); |
| 38 | if (ret->cond == NULL) { |
| 39 | ErrSdl(); |
| 40 | } |
| 41 | return ret; |
| 42 | } |
| 43 | |
| 44 | void EndEvent(event_emul *event) |
| 45 | { |