summaryrefslogtreecommitdiffstats
path: root/src/efi.c
diff options
context:
space:
mode:
authorDavid Sommerseth <davids@redhat.com>2010-02-05 15:33:39 +0100
committerDavid Sommerseth <davids@redhat.com>2010-02-05 15:33:39 +0100
commit5ebf67efee2893c4d3dc60ec31a0efeb0894d245 (patch)
tree337c4ff23b1498096e64179dadddf8b39a81e340 /src/efi.c
parent24af40698f1486c899333ea1f129e87590cdee7e (diff)
downloadpython-dmidecode-5ebf67efee2893c4d3dc60ec31a0efeb0894d245.tar.gz
python-dmidecode-5ebf67efee2893c4d3dc60ec31a0efeb0894d245.tar.xz
python-dmidecode-5ebf67efee2893c4d3dc60ec31a0efeb0894d245.zip
Added logging flag to log_append() to change log behaviour
Valid flags are: * LOGFL_NORMAL Log all messages to the log context, and send log message to stderr on errors * LOGFL_NODUPS Log only unique messages. Duplicated messages will be removed * LOGFL_NOSTDERR Don't write to stderr, even if errors occur
Diffstat (limited to 'src/efi.c')
-rw-r--r--src/efi.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/efi.c b/src/efi.c
index af0a813..171ae30 100644
--- a/src/efi.c
+++ b/src/efi.c
@@ -76,8 +76,9 @@ int address_from_efi(Log_t *logp, size_t * address)
if(fclose(efi_systab) != 0)
perror(filename);
- if(ret == EFI_NO_SMBIOS)
- log_append(logp, LOG_WARNING, "%s: SMBIOS entry point missing\n", filename);
+ if(ret == EFI_NO_SMBIOS) {
+ log_append(logp, LOGFL_NODUPS, LOG_WARNING, "%s: SMBIOS entry point missing\n", filename);
+ }
return ret;
}