Home | History | Annotate | Download | only in MagickCore

Lines Matching refs:log_info

305       *log_info;
311 log_info=(LogInfo *) AcquireMagickMemory(sizeof(*log_info));
312 if (log_info == (LogInfo *) NULL)
318 (void) ResetMagickMemory(log_info,0,sizeof(*log_info));
319 log_info->path=ConstantString("[built-in]");
320 GetTimerInfo((TimerInfo *) &log_info->timer);
321 log_info->event_mask=p->event_mask;
322 log_info->handler_mask=p->handler_mask;
323 log_info->filename=ConstantString(p->filename);
324 log_info->format=ConstantString(p->format);
325 log_info->signature=MagickCoreSignature;
326 status&=AppendValueToLinkedList(cache,log_info);
329 ResourceLimitError,"MemoryAllocationFailed","`%s'",log_info->name);
359 *log_info;
364 log_info=GetLogInfo("*",exception);
367 if (log_info->file != (FILE *) NULL)
369 (void) FormatLocaleFile(log_info->file,"</log>\n");
370 (void) fclose(log_info->file);
371 log_info->file=(FILE *) NULL;
708 *log_info;
717 log_info=GetLogInfo("*",exception);
719 return(log_info->event_mask != NoEvents ? MagickTrue : MagickFalse);
753 **log_info;
766 log_info=GetLogInfoList("*",&number_aliases,exception);
767 if (log_info == (const LogInfo **) NULL)
773 if (log_info[i]->stealth != MagickFalse)
776 (LocaleCompare(path,log_info[i]->path) != 0))
781 if (log_info[i]->path != (char *) NULL)
782 (void) FormatLocaleFile(file,"\nPath: %s\n\n",log_info[i]->path);
793 if ((log_info[i]->handler_mask & mask) != 0)
805 path=log_info[i]->path;
806 if (log_info[i]->filename != (char *) NULL)
808 (void) FormatLocaleFile(file,"%s",log_info[i]->filename);
809 for (j=(ssize_t) strlen(log_info[i]->filename); j <= 16; j++)
812 (void) FormatLocaleFile(file,"%9g ",(double) log_info[i]->generations);
813 (void) FormatLocaleFile(file,"%8g ",(double) log_info[i]->limit);
814 if (log_info[i]->format != (char *) NULL)
815 (void) FormatLocaleFile(file,"%s",log_info[i]->format);
819 log_info=(const LogInfo **) RelinquishMagickMemory((void *) log_info);
876 static void *DestroyLogElement(void *log_info)
881 p=(LogInfo *) log_info;
962 *log_info;
977 log_info=(LogInfo *) GetLogInfo("*",exception);
980 elapsed_time=GetElapsedTime(&log_info->timer);
981 user_time=GetUserTime(&log_info->timer);
983 if (log_info->format == (char *) NULL)
986 if (LocaleCompare(log_info->format,"xml") == 0)
1018 for (p=log_info->format; *p != '\0'; p++)
1092 if (log_info->generations == 0)
1098 q+=FormatLocaleString(q,extent,"%.20g",(double) (log_info->generation %
1099 log_info->generations));
1170 static char *TranslateFilename(const LogInfo *log_info)
1187 assert(log_info != (LogInfo *) NULL);
1188 assert(log_info->filename != (char *) NULL);
1192 for (p=log_info->filename; *p != '\0'; p++)
1229 if (log_info->generations == 0)
1235 q+=FormatLocaleString(q,extent,"%.20g",(double) (log_info->generation %
1236 log_info->generations));
1288 *log_info;
1293 log_info=(LogInfo *) GetLogInfo("*",exception);
1298 if ((log_info->event_mask & type) == 0)
1314 (void) ContinueTimer((TimerInfo *) &log_info->timer);
1318 if ((log_info->handler_mask & ConsoleHandler) != 0)
1323 if ((log_info->handler_mask & DebugHandler) != 0)
1330 if ((log_info->handler_mask & EventHandler) != 0)
1336 if ((log_info->handler_mask & FileHandler) != 0)
1342 if (log_info->file != (FILE *) NULL)
1343 (void) fstat(fileno(log_info->file),&file_info);
1344 if (file_info.st_size > (ssize_t) (1024*1024*log_info->limit))
1346 (void) FormatLocaleFile(log_info->file,"</log>\n");
1347 (void) fclose(log_info->file);
1348 log_info->file=(FILE *) NULL;
1350 if (log_info->file == (FILE *) NULL)
1355 filename=TranslateFilename(log_info);
1358 (void) ContinueTimer((TimerInfo *) &log_info->timer);
1362 log_info->append=IsPathAccessible(filename);
1363 log_info->file=fopen_utf8(filename,"ab");
1365 if (log_info->file == (FILE *) NULL)
1370 log_info->generation++;
1371 if (log_info->append == MagickFalse)
1372 (void) FormatLocaleFile(log_info->file,"<?xml version=\"1.0\" "
1374 (void) FormatLocaleFile(log_info->file,"<log>\n");
1376 (void) FormatLocaleFile(log_info->file," <event>%s</event>\n",text);
1377 (void) fflush(log_info->file);
1379 if ((log_info->handler_mask & MethodHandler) != 0)
1381 if (log_info->method != (MagickLogMethod) NULL)
1382 log_info->method(type,text);
1384 if ((log_info->handler_mask & StdoutHandler) != 0)
1389 if ((log_info->handler_mask & StderrHandler) != 0)
1395 (void) ContinueTimer((TimerInfo *) &log_info->timer);
1457 *log_info = (LogInfo *) NULL;
1548 log_info=(LogInfo *) AcquireMagickMemory(sizeof(*log_info));
1549 if (log_info == (LogInfo *) NULL)
1551 (void) ResetMagickMemory(log_info,0,sizeof(*log_info));
1552 log_info->path=ConstantString(filename);
1553 GetTimerInfo((TimerInfo *) &log_info->timer);
1554 log_info->signature=MagickCoreSignature;
1557 if (log_info == (LogInfo *) NULL)
1561 status=AppendValueToLinkedList(cache,log_info);
1565 log_info=(LogInfo *) NULL;
1580 log_info->event_mask=(LogEventType) (log_info->event_mask |
1591 if (log_info->filename != (char *) NULL)
1592 log_info->filename=(char *)
1593 RelinquishMagickMemory(log_info->filename);
1594 log_info->filename=ConstantString(token);
1599 if (log_info->format != (char *) NULL)
1600 log_info->format=(char *)
1601 RelinquishMagickMemory(log_info->format);
1602 log_info->format=ConstantString(token);
1614 log_info->generations=(~0UL);
1617 log_info->generations=StringToUnsignedLong(token);
1629 log_info->limit=(~0UL);
1632 log_info->limit=StringToUnsignedLong(token);
1642 log_info->handler_mask=(LogHandlerType)
1643 (log_info->handler_mask | ParseLogHandlers(token));
1748 *log_info;
1754 log_info=(LogInfo *) GetLogInfo("*",exception);
1758 log_info=(LogInfo *) GetValueFromLinkedList(log_cache,0);
1759 log_info->event_mask=(LogEventType) option;
1761 log_info->event_mask=UndefinedEvents;
1763 return(log_info->event_mask);
1792 *log_info;
1798 log_info=(LogInfo *) GetLogInfo("*",exception);
1801 if (log_info->format != (char *) NULL)
1802 log_info->format=DestroyString(log_info->format);
1803 log_info->format=ConstantString(format);
1836 *log_info;
1839 log_info=(LogInfo *) GetLogInfo("*",exception);
1842 log_info=(LogInfo *) GetValueFromLinkedList(log_cache,0);
1843 log_info->handler_mask=(LogHandlerType) (log_info->handler_mask |
1845 log_info->method=method;