summaryrefslogtreecommitdiff
path: root/lib/headerfmt.c
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2008-09-18 12:36:31 +0300
committerPanu Matilainen <pmatilai@redhat.com>2008-09-18 12:36:31 +0300
commit9a9f3c3abbab8981cd1397ddee5a16b4ce65e353 (patch)
treeb34f76debb3461fed138cdf412162586d1e03fae /lib/headerfmt.c
parent9da6dce0e68cfe1290e4001def4e5adebb8bf37b (diff)
downloadrpm-9a9f3c3abbab8981cd1397ddee5a16b4ce65e353.tar.gz
Don't segfault on unknown format specifiers
Diffstat (limited to 'lib/headerfmt.c')
-rw-r--r--lib/headerfmt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/headerfmt.c b/lib/headerfmt.c
index 1c05c89b0..2800d1956 100644
--- a/lib/headerfmt.c
+++ b/lib/headerfmt.c
@@ -256,7 +256,7 @@ bingo:
if (stag->type != NULL)
stag->fmt = rpmHeaderFormatFuncByName(stag->type);
- return 0;
+ return stag->fmt ? 0 : 1;
}
/* forward ref */