Module Name:    src
Committed By:   dholland
Date:           Wed May 21 05:25:34 UTC 2014

Modified Files:
        src/usr.bin/config: files.c

Log Message:
avoid error path SIGSEGV


To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/usr.bin/config/files.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.bin/config/files.c
diff -u src/usr.bin/config/files.c:1.11 src/usr.bin/config/files.c:1.12
--- src/usr.bin/config/files.c:1.11	Sun Mar 11 08:21:53 2012
+++ src/usr.bin/config/files.c	Wed May 21 05:25:34 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: files.c,v 1.11 2012/03/11 08:21:53 dholland Exp $	*/
+/*	$NetBSD: files.c,v 1.12 2014/05/21 05:25:34 dholland Exp $	*/
 
 /*
  * Copyright (c) 1992, 1993
@@ -160,7 +160,9 @@ addfile(const char *path, struct condexp
 	TAILQ_INSERT_TAIL(&allfiles, fi, fi_next);
 	return;
  bad:
-	condexpr_destroy(optx);
+	if (optx != NULL) {
+		condexpr_destroy(optx);
+	}
 }
 
 void

Reply via email to