mirror of
https://git.lyx.org/repos/lyx.git
synced 2025-01-03 08:28:25 +00:00
Don't forget the Windows drive name when mangling the temporary file name.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9393 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
3dd565beae
commit
c7d1778e3f
@ -1,3 +1,9 @@
|
|||||||
|
2004-12-16 Angus Leeming <leeming@lyx.org>
|
||||||
|
|
||||||
|
* filename.C (mangledFilename): Given a Windows-style path, don't
|
||||||
|
forget to mangle the drive letter too when generating a unique
|
||||||
|
temporary file name.
|
||||||
|
|
||||||
2004-12-16 Angus Leeming <leeming@lyx.org>
|
2004-12-16 Angus Leeming <leeming@lyx.org>
|
||||||
|
|
||||||
* mkdir.C: move the HAVE_MKDIR conditional code out of config.h
|
* mkdir.C: move the HAVE_MKDIR conditional code out of config.h
|
||||||
|
@ -86,6 +86,13 @@ string const FileName::mangledFilename() const
|
|||||||
mname = subst(mname, ".", "_");
|
mname = subst(mname, ".", "_");
|
||||||
// Add the extension back on
|
// Add the extension back on
|
||||||
mname = ChangeExtension(mname, GetExtension(name_));
|
mname = ChangeExtension(mname, GetExtension(name_));
|
||||||
|
|
||||||
|
#if defined(__CYGWIN__) || defined(__CYGWIN32__) || defined(_WIN32)
|
||||||
|
// Mangle the drive letter in a Windows-style path.
|
||||||
|
if (mname.size() >= 2 && mname[1] == ':')
|
||||||
|
mname[1] = '_';
|
||||||
|
#endif
|
||||||
|
|
||||||
// Prepend a counter to the filename. This is necessary to make
|
// Prepend a counter to the filename. This is necessary to make
|
||||||
// the mangled name unique.
|
// the mangled name unique.
|
||||||
static int counter = 0;
|
static int counter = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user