Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Vlad Seryakov
Yes, works fine now, Thanks Stephen Deasey wrote: > On 10/13/07, Vlad Seryakov <[EMAIL PROTECTED]> wrote: >> I was able to find the location which causes the crash but i am not sure >> how to fix it >> >> In function Ns_VALog i call vsnprintf directly, it works, when it is >> called via Ns_DString

Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Stephen Deasey
On 10/13/07, Vlad Seryakov <[EMAIL PROTECTED]> wrote: > I was able to find the location which causes the crash but i am not sure > how to fix it > > In function Ns_VALog i call vsnprintf directly, it works, when it is > called via Ns_DStringVPintf it crashes. using va_copy does not help > diff -r

Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Vlad Seryakov
with included old dsprintf.c it works fine Vlad Seryakov wrote: > I was able to find the location which causes the crash but i am not sure > how to fix it > > In function Ns_VALog i call vsnprintf directly, it works, when it is > called via Ns_DStringVPintf it crashes. using va_copy does not he

Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Vlad Seryakov
I was able to find the location which causes the crash but i am not sure how to fix it In function Ns_VALog i call vsnprintf directly, it works, when it is called via Ns_DStringVPintf it crashes. using va_copy does not help { char buf[4096]; vsnprintf(buf, sizeof(buf

Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Vlad Seryakov
When i replaced Ns_VALog with pure vfprintf it does not crash anymore, so it is definitely something with passing va_list. I tried as discussed here but it still crashes: http://osdir.com/ml/redhat.amd64/2006-12/msg1.html void Ns_Log(Ns_LogSeverity severity, CONST char *fmt, ...) { va_l

Re: [naviserver-devel] Crash in x64 mode in Ns_Log

2007-10-13 Thread Gustaf Neumann
there is nothing wrong on using *va_list in general. the problem is rather in vsnprintf, which does most probably a loop like in Ns_DStringVarAppend char * Ns_DStringVarAppend(Ns_DString *dsPtr, ...) { register char *s; va_list ap; va_start(ap, dsPtr); while ((s = va_arg

Re: [naviserver-devel] ns_config read/write

2007-10-13 Thread Vasiljevic Zoran
On 13.10.2007, at 00:06, Vlad Seryakov wrote: > In it will not hurt performance when constantly asking for config > parameter with locking i am fine with it. Locking is of course necessary. But it is limited to locking one mutex and, more importantly, the locking contention is only between one r