| 812 | } |
| 813 | |
| 814 | void fx_clearTimer(txMachine* the) |
| 815 | { |
| 816 | if ((0 == mxArgc) || (XS_REFERENCE_KIND != mxArgv(0)->kind) || (C_NULL == fxGetHostDataIf(the, mxArgv(0)))) |
| 817 | return; |
| 818 | txHostHooks* hooks = fxGetHostHooks(the, mxArgv(0)); |
| 819 | if (hooks == &gxTimerHooks) { |
| 820 | txJob* job = fxGetHostData(the, mxArgv(0)); |
| 821 | if (job) { |
| 822 | fxForget(the, &job->self); |
| 823 | fxSetHostData(the, mxArgv(0), NULL); |
| 824 | job->the = NULL; |
| 825 | txSharedTimer* timer = (txSharedTimer*)(((txByte*)job) - offsetof(txSharedTimer, refcon)); |
| 826 | fxRescheduleSharedTimer(timer, 0, 0); |
| 827 | } |
| 828 | } |
| 829 | } |
| 830 | |
| 831 | void fx_destroyTimer(void* data) |
| 832 | { |
nothing calls this directly
no test coverage detected