Thanks for the quick reply and fix but with the latest version of log.c I can create a StackOverflowException when I add the following to identify.c:
Code: Select all
utf8=NTArgvToUTF8(argc,argv);
SetLogEventMask("All");
And log.xml file contains:
This is happening because 'AppendValueToLinkedList' does the following:
Code: Select all
list_info->debug=IsEventLogging();
if (list_info->debug != MagickFalse)
(void) LogMagickEvent(TraceEvent,GetMagickModule(),"...");
When the xml file has been loaded the result of the method will be 'MagickTrue' and the next line will write something to the log. This will call 'IsEventLogging' that does the following:
Code: Select all
if ((log_list == (LinkedListInfo *) NULL) ||
(IsLinkedListEmpty(log_list) != MagickFalse))
return(MagickFalse);
And in IsLinkedListEmpty something will be written to the log again (and 'IsEventLogging' will be called again....):
Code: Select all
if (list_info->debug != MagickFalse)
(void) LogMagickEvent(TraceEvent,GetMagickModule(),"...");
It is probably a good idea to disable logging for 'log_list'.