Port-sparc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: ntpd wedged by libc?



On 3/6/2012 10:41, AGC wrote:
On 3/6/2012 08:18, Christos Zoulas wrote:
On Mar 6, 3:01pm, hart%ntp.org@localhost (Dave Hart) wrote:

| There have been over 50 messages in the thread, so I think we can all
| be forgiven forgetting a detail or two along the way, but I don't
| think anyone has suggested the original leak bug hasn't been fixed.
| Rather, it seems there is still some sort of problem on "5.1" (not
| -current, clearly) on sparc with ntpd being polled every few seconds
| by ntpq triggering a hang snprintf'ing with floating point.
|
| The stack trace looks very similar to the first go-around. If
| accurate, it suggests the same code still has issues that ntpd's abuse
| tickles but t_printf.c doesn't.

Sure, let's change the test to be closer to the ntp one, let's make the
format %.3f for example. The way I tracked it down initially was by
instrumenting all malloc/free's in the dtoa code...

I changed the format to %.6f since there are a few calls within ntpd
that are of that precision or more. I'll recompile and test.


I ran the test with both %.6f and stepped it up even further all the way to %.10f with no ill effects. The test passed all the extra precision formats:

tc-start: snprintf_float
__atf_tc_separator__
__atf_tc_separator__
tc-end: snprintf_float, passed



Home | Main Index | Thread Index | Old Index