Keith Thompson wrote On 10/01/07 16:00,:
[...]
I'll use fork() as a (perhaps hypothetical) example.
The valid point, of course, is that fork() is not part of standard C,
and is therefore off-topic here in comp.lang.c. But I submit that
when you respond as I've described above, you're being less than
helpful. Someone who's trying to solve a problem in his program that
uses fork() is interested in getting a solution, not in conforming to
the topicality rules of comp.lang.c. A helpful answer is to point out
that fork is non-standard, and to suggest posting to a system-specific
newsgroup. Pretending (I assume it's a pretense) that you don't know
what fork() really is, or at least have a pretty good idea that it's
Unix-specific, is disingenuous. Nobody is *really* going to provide a
portable standard C implementation of fork().
Yabbut, if the question concerns fork() in any
essential way, like "Does a successful call to fork()
double the swap space allocation?" or "Does the new
process preempt the old one immediately, or does the
old keep on executing for a while?" then the question
really really really isn't about C. Even if you know
something about fork(), the best answer you can give
is probably "It depends."
Personally, I've no reluctance to answering questions
that involve stat() or open() or whatever, if I perceive
them as being involved "incidentally." If a code snippet
shows input being obtained from recv() and the question
is about how to manage memory allocation for the received
data, I see no reason not to discuss the proper use of
malloc() et al. On the other hand, a question about how
to use recv()'s MSG_PEEK flag is a clear candidate for
"Try another newsgroup; you'll get better answers."
IMHO, fork() is a function for which practically all
serious questions fall into the second category.