From cb28ab77bc185190e3e6f7337565344dd42895a3 Mon Sep 17 00:00:00 2001 From: =?utf8?q?J=C3=BCrgen=20Spitzm=C3=BCller?= Date: Sun, 30 Sep 2007 12:38:08 +0000 Subject: [PATCH] * src/insets/InsetGraphics.cpp (prepareFile): - Fix wrong external_path that triggered an assert on Windows while exporting to LaTeX (bug 4243). git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20607 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/insets/InsetGraphics.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/insets/InsetGraphics.cpp b/src/insets/InsetGraphics.cpp index 4f58f76ac3..cff5a843ea 100644 --- a/src/insets/InsetGraphics.cpp +++ b/src/insets/InsetGraphics.cpp @@ -627,13 +627,12 @@ string const InsetGraphics::prepareFile(Buffer const & buf, if (status == FAILURE) return orig_file; - // a relative filename should be relative to the master - // buffer. + // a relative filename should be relative to the master buffer. // "nice" means that the buffer is exported to LaTeX format but not - // run through the LaTeX compiler. - string output_file = support::os::external_path(runparams.nice ? + // run through the LaTeX compiler. + string output_file = runparams.nice ? params().filename.outputFilename(m_buffer->filePath()) : - onlyFilename(temp_file.absFilename())); + onlyFilename(temp_file.absFilename()); if (runparams.nice && !isValidLaTeXFilename(output_file)) { frontend::Alert::warning(_("Invalid filename"), -- 2.39.5