find_in_path() is supposed to work with a NULL path, but didn't. Fix it.
diff --git a/lib/lib.c b/lib/lib.c
index fa0b777..52675d5 100644
--- a/lib/lib.c
+++ b/lib/lib.c
@@ -194,10 +194,13 @@
 struct string_list *find_in_path(char *path, char *filename)
 {
   struct string_list *rlist = NULL, **prlist=&rlist;
-  char *cwd = xgetcwd();
+  char *cwd;
 
+  if (!path) return 0;
+
+  cwd = xgetcwd();
   for (;;) {
-    char *next = path ? strchr(path, ':') : NULL;
+    char *next = strchr(path, ':');
     int len = next ? next-path : strlen(path);
     struct string_list *rnext;
     struct stat st;