* src/expand-common.c (next_file): We're dependent on calling
this function with NULL to initialize things appropriately.
So enforce this with assert(), which avoids a warning from
clang-anaylzer.
---
src/expand-common.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/expand-common.c b/src/expand-common.c
index 0728e70..e1b549f 100644
--- a/src/expand-common.c
+++ b/src/expand-common.c
@@ -16,6 +16,7 @@
#include <config.h>
+#include <assert.h>
#include <stdio.h>
#include <sys/types.h>
#include "system.h"
@@ -282,6 +283,7 @@ next_file (FILE *fp)
if (fp)
{
+ assert (prev_file);
if (ferror (fp))
{
error (0, errno, "%s", quotef (prev_file));
--
2.9.3