0

我使用 sbcl 并且我有一个线程,它只执行特定任务(将某些内容写入文件),进入睡眠 30 秒并重复。

我想要实现的是:如果用户希望程序停止,线程应立即唤醒,写入文件并自行停止。

谁能给我一个提示?亲切的问候,帕特里克

4

1 回答 1

1

Bordeaux-threads doesn't have such feature, so you should use the signal handling facilities of your implementation. Maybe cl-signal-handler can be useful. Also see this question for some additional details.

于 2012-12-27T18:30:20.010 回答