[Gc] Re: Avoid ABORT() in GC_log_printf
Kjetil Matheussen
k.s.matheussen at notam02.no
Tue Nov 20 09:00:48 PST 2012
Hi Ivan,
Thanks for quick reply!
And thanks for the tips!
My target, when I got the error, was mingw32. I haven't seen
the same error when compiling for linux or osx. (But I don't
usually test those versions in a read-only directory either)
> 3. By default, GC_log_printf write to stderr.
That's strange, since it has generated this file:
-rw-rw-r-- 1 kjetil kjetil 120 2012-11-19 18:16 radium.bin.gc.log
I cross compile my program using fedora 17, maybe something went
wrong when setting the default target for GC_log_printf.
I'm pretty sure bdw-gc was compiled like this:
mingw32-configure && mingw32-make
On 20.11.2012 16:59, Ivan Maidanski wrote:
> Hi Kjetil,
>
> 1. New abort function could be set via GC_set_abort_func.
> 2. You haven't specified your target.
> 3. By default, GC_log_printf write to stderr.
> 4. If you want to permanently ignore GC_log, you could pass
> -DGC_LOG_TO_FILE_ALWAYS -DGC_LOG_STD_NAME="/dev/null"
> 4. What should GC do in case of error?
>
> Regards,
> Ivan
>
> Tue 20 Nov 2012 16:25:48 Kjetil Matheussen :
>
>> Hi,
>>
>> I just got a crash which I think was caused by running my program
>> in a
>> read-only directory.
>>
>> WRITE failed in GC_log_printf, and then ABORT() was called.
>>
>> Perhaps there is a configuration flag I can set which prevents
>> ABORT
>> from aborting?
>> (didn't find any though). I don't want the garbage collector to
>> abort
>> the program
>> in production code, even if it could be a serious error.
>>
>> I'll just redefine ABORT for now, but I think the default behavior
>> needs to be changed.
>> (It could of course also be that I have misunderstood something)
>>
>> -Kjetil
>>
>> _______________________________________________
>> Gc mailing list
>> Gc at linux.hpl.hp.com [1]
>> http://www.hpl.hp.com/hosted/linux/mail-archives/gc/ [2]
>
>
>
> Links:
> ------
> [1]
> http://www.eposttjener.no/sentmsg?compose|+|amp|+|To=Gc@linux.hpl.hp.com
> [2] http://www.hpl.hp.com/hosted/linux/mail-archives/gc/
More information about the Gc
mailing list