- * In a threaded program such as VLC, the only sane way to handle signals
- * is to block them in all threads but one - this is the only way to
- * predict which thread will receive them. If any piece of code depends
- * on delivery of one of this signal it is intrinsically not thread-safe
- * and MUST NOT be used in VLC, whether we like it or not.
- * There is only one exception: if the signal is raised with
- * pthread_kill() - we do not use this in LibVLC but some pthread
- * implementations use them internally. You should really use conditions
- * for thread synchronization anyway.
+ * There are two advantages to sigwait() over traditional signal handlers:
+ * - delivery is synchronous: no need to worry about async-safety,
+ * - EINTR is not generated: other threads need not handle that error.
+ * That being said, some LibVLC programs do not use sigwait(). Therefore
+ * EINTR must still be handled cleanly, notably from poll() calls.