]> git.lyx.org Git - features.git/commitdiff
Fix bug #11490
authorEnrico Forestieri <forenr@lyx.org>
Tue, 19 Feb 2019 18:51:11 +0000 (19:51 +0100)
committerEnrico Forestieri <forenr@lyx.org>
Tue, 19 Mar 2019 20:41:04 +0000 (21:41 +0100)
Correctly add the branch name suffix when the stem
of the filename contains a dot.

(cherry picked from commit c3b950483565ca53265a4105a4946585f8b59e24)

src/Buffer.cpp
status.23x

index 354173e8cb2c04e64a19c388cf85ccb99af212ca..881968963613093f1b5eaaf3f341276bf1a908aa 100644 (file)
@@ -824,10 +824,9 @@ FileName Buffer::Impl::exportFileName() const
        if (branch_suffix.empty())
                return filename;
 
-       string const name = filename.onlyFileNameWithoutExt()
-               + to_utf8(branch_suffix);
+       string const name = addExtension(filename.onlyFileNameWithoutExt()
+                       + to_utf8(branch_suffix), filename.extension());
        FileName res(filename.onlyPath().absFileName() + "/" + name);
-       res.changeExtension(filename.extension());
 
        return res;
 }
index b55dd8ddfd871a36fad187a26b105c6cc68f7444..5216b09953a464e282212672fb381867148bed8c 100644 (file)
@@ -97,6 +97,9 @@ What's new
 - Fix LaTeX error caused by Control key shortcut inset on the Mac (remainder
   of bug 10641).
 
+- Correctly add the branch name suffix when the stem of the filename
+  contains a dot (bug 11490).
+
 
 * USER INTERFACE