aboutsummaryrefslogtreecommitdiff
path: root/src/zonefile.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/zonefile.c')
-rw-r--r--src/zonefile.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/zonefile.c b/src/zonefile.c
index 1b0d036..1701ff8 100644
--- a/src/zonefile.c
+++ b/src/zonefile.c
@@ -52,6 +52,10 @@ int zonefile_parse_line(database_t *_database, char *_line) {
return -1;
}
qname = malloc( (unsigned)fqdn_len+2 );
+ if( !qname ) {
+ LOGPRINTF(_LOG_ERRNO, "malloc()");
+ return -1;
+ }
if ( fqdn_to_qname(parts[0], fqdn_len, qname, fqdn_len+2) < 0) {
LOGPRINTF(_LOG_ERROR, "Failed to convert to QNAME. This is a bug.");
return -1;