Well, in your specific case you could replace it only in files that are *.c or *.h, you can easily use an additional parameter to "find" to accomplish that:
On Mon, Oct 6, 2008 at 12:34, tony.chamberlain@lemko.com wrote:
find . -type f | while read fil do sed -i 's/prog/name/g' $f # change "prog" to "name" done
Use instead:
find . -type f -name '*.[ch]' | ...
Maybe not what you're looking for, but from your examples that's how I would approach it.
HTH, Filipe