From 688070a52955c1046a3b2a373956725926703c9d Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 14 Jan 2012 20:16:28 +0200 Subject: Allow visiting Info files with no "Up" pointer, such as DIR files. lisp/info.el (Info-toc-build): If the Info file has no "Up" pointer, don't pass the (nil) value of `upnode' to string-match. --- lisp/info.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lisp/info.el') diff --git a/lisp/info.el b/lisp/info.el index 94d29518995..a8cb141114c 100644 --- a/lisp/info.el +++ b/lisp/info.el @@ -2251,7 +2251,7 @@ Table of contents is created from the tree structure of menus." (match-string-no-properties 1))) (section "Top") menu-items) - (when (string-match "(" upnode) (setq upnode nil)) + (when (and upnode (string-match "(" upnode)) (setq upnode nil)) (when (and (not (Info-index-node nodename file)) (re-search-forward "^\\* Menu:" bound t)) (forward-line 1) -- cgit v1.2.1