Re: Deadlock (busy loop) on panic/SIGSEGV case in Go API user code

yzh杨振宏 <[email protected]>
Newsgroups gmane.comp.video.graphicsmagick.help
Message-ID <7354BE8391D7C34B9384A115F0B5444A20A753EE@SVR2115HP380.cn1.global.ctrip.com>
I test it and encounter same problem as Kagami Hiiragi. 
I prefer the option 1) and 2) too. 3) is not enough to solve all the problem, because sa_mask/sa_flags other languages API users using may be different from GO's.

-----邮件原件-----
发件人: Kagami Hiiragi <[email protected]> 
发送时间: 2018年3月17日 4:45
收件人: [email protected]
主题: Re: [GM-help] Deadlock (busy loop) on panic/SIGSEGV case in Go API user code

Oops, accidentally sent to personal email instead of maillist.

On 16/03/18 23:08, Bob Friesenhahn wrote:
> On Fri, 16 Mar 2018, Kagami Hiiragi wrote:
>>
>> It would be even better to not set any handlers for API users at all, 
>> unless requested, but as you said before it might cause ABI change...
> 
> As mentioned before, it could be handled via internal library properties which can be set prior to InitalizeMagick() without breaking the existing ABI.  There would only be one or two more new functions.
> 
> The draconian signal handlers in GM are intended to avoid leaking temporary files.  Without these handlers, the using application then takes responsibility to try not to leak temporary files.
> 
> Bob

Thanks for clarification.

So seems like there are three options available:

1) Add function to API to disable GM's signal handlers
2) Don't re-set Go handlers
3) Set sa_mask/sa_flags which would make Go happy

Any of this is probably ok to avoid issue in question. Personally I like options 1) and 2) more.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________
Graphicsmagick-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/graphicsmagick-help
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Graphicsmagick-help mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/graphicsmagick-help
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.