in reply to How to catch a broken input pipe

I assume you mean here that the application is written in Perl, and that the xinetd daemon opens it through a pipe and begins writing data to the applications STDIN. In that case you can use the simple <> operator on the Perl side, and as soon as the client connection is broken <> will return undef. More generally, <$fh> will return undef as soon as $fh is closed regardless of how it was opened (by creating a pipe, by accepting a client socket connection, etc).