On Tue, Sep 01, 2015 at 12:04:33PM -0400, Scott Kostyshak wrote: > On Tue, Sep 1, 2015 at 12:01 PM, Richard Heck <rgh...@lyx.org> wrote: > > On 09/01/2015 11:54 AM, Scott Kostyshak wrote: > >> > >> On Tue, Sep 1, 2015 at 11:39 AM, Richard Heck <rgh...@lyx.org> wrote: > >>> > >>> On 09/01/2015 11:37 AM, Kornel Benko wrote: > >>>> > >>>> Am Dienstag, 1. September 2015 um 17:05:06, schrieb Richard Heck > >>>> <rgh...@lyx.org> > >>>>> > >>>>> - filename clipart/mobius.eps > >>>>> + filename /cvs/lyx/lyx-devel/lib/doc/clipart/mobius.eps > >>>> > >>>> Really absolute path? > >>> > >>> > >>> This conversion was done automatically on save. Wasn't there some change > >>> made along ehse lines? > >> > >> Yes. It was changed to be a preference. I thought the preference was > >> off by default though. In any case, look at Preferences > Document > >> Handling at "Save the document directory path". > > > > > > It is unchecked. Still, saving the file writes absolute paths. > > This could be a bug then. I don't have time to try to reproduce at the > moment. Let's see if Enrico has an idea.
I bet that at least one of the path components used by Richard is a symlink. Does the attached patch solve the issue? -- Enrico
diff --git a/src/Buffer.cpp b/src/Buffer.cpp index 09cff3c..4d46732 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -4949,7 +4949,8 @@ string Buffer::includedFilePath(string const & name, string const & ext) const // old_position already contains a trailing path separator string const absname = isabsolute ? name : d->old_position + name; - if (d->old_position.empty() || d->old_position == filePath() + if (d->old_position.empty() + || equivalent(FileName(d->old_position), FileName(filePath())) || !FileName(addExtension(absname, ext)).exists()) return name;