-*- text -*- o a service limited to a single instance but with multiple incoming sockets. the pure approach is to block all sockets once the limit is exceeded. this is silly - if you have a udp client listening on n sockets, then you can have n instances, each hogging a single socket. this is tres cool, and makes the fd code in engine.c and signals.c much simpler. the downside is that then the meaning of 'instances' changes from 'the number of instances that run simultaneously' to something weird, that is better expressed as 'the number of instances that can run simultaneously is instances + the number of sockets, if more than one'. blah. How about a semaphore with a limit of 1? sem->match = { OP_REMOVEMYFDFROMLISTENLIST, OP_DOWN, me }; sem->under = NULL; pidtab->onexit = { OP_ADDMYFDBACKINTOLISTENLIST };