At 9:29 AM -0400 7/27/99, Tim Vanderhoek wrote:
> On a file with 100000+ lines, the speed difference is rather
> restrictive. [...] Only about 10% of the time is spend in
> procline(). There seems to be a lot of unnecessary strncpy()
> that could be _easily_ avoided if free() on util.c:130 was
> avoided, but I'll let the authors speak first. :-)
Hmm, strncpy? Are these calls which really want strncpy
for what it was originally designed for, or are they just
trying to prevent buffer overruns?
If it's the buffer-overrun answer, then maybe this would
be a good test case for using strlcpy instead of strncpy,
and see if it makes a performance difference (since the
code won't waste it's time nulling-out bytes that don't
need to be nulled-out).
---
Garance Alistair Drosehn = [EMAIL PROTECTED]
Senior Systems Programmer or [EMAIL PROTECTED]
Rensselaer Polytechnic Institute
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message