emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Build failure on M$ (using MSVC): Patch enclosed


From: Stefan Monnier
Subject: Re: Build failure on M$ (using MSVC): Patch enclosed
Date: Wed, 21 May 2008 13:28:32 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

> diff --git a/lisp/files.el b/lisp/files.el
> index ee5efe4..bb8a021 100644
> --- a/lisp/files.el
> +++ b/lisp/files.el
> @@ -3120,8 +3120,9 @@ If the file is in a registered project, a cons from
>  `project-directory-alist' is returned.
>  Otherwise this returns nil."
>    (let ((dir (file-name-directory file))
> -     (result nil))
> -    (while (and (not (string= dir "/"))
> +        (result nil)
> +        (prevdir nil))
> +    (while (and (not (string= dir prevdir))
>               (not result))
>        (cond
>         ((setq result (assoc dir project-directory-alist))
> @@ -3130,6 +3131,7 @@ Otherwise this returns nil."
>         ((file-exists-p (expand-file-name ".dir-settings.el" dir))
>       (setq result (expand-file-name ".dir-settings.el" dir)))
>         (t
> +        (setq prevdir dir)
>       (setq dir (file-name-directory (directory-file-name dir))))))
>      result))

Actually, why doesn't this code use locate-dominating-file?


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]