shithub: mc

Download patch

ref: d29f8b95128b46048e5dbac897dc27fe70efe3c0
parent: a563b40a6af1ee03729918c8a15b48e06bcdeec2
author: Ori Bernstein <ori@eigenstate.org>
date: Fri Jan 22 21:24:42 EST 2016

Print search path on failing to load usefile.

--- a/parse/use.c
+++ b/parse/use.c
@@ -1020,9 +1020,10 @@
 		}
 	}
 	if (!fd) {
-		fatal(use, "could not open usefile %s in", use->use.name);
+		fprintf(stderr, "could not open usefile %s in search path:\n", use->use.name);
 		for (i = 0; i < nincpaths; i++)
-			printf("\t%s\n", incpaths[i]);
+			fprintf(stderr, "\t%s\n", incpaths[i]);
+		exit(1);
 	}
 
 	if (!loaduse(p, fd, st, vis))