summaryrefslogtreecommitdiffstats
path: root/src/filename.cpp
diff options
context:
space:
mode:
authordimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2000-05-22 18:35:23 (GMT)
committerdimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7>2000-05-22 18:35:23 (GMT)
commitf38608d4bec002a5051c860a599dd4d5229a9671 (patch)
tree699a18c9a8c098fc845ba00c7eb093c73b497c5c /src/filename.cpp
parent8013b5fe71402e6c6bfd867e348b6cad73bd7386 (diff)
downloadDoxygen-f38608d4bec002a5051c860a599dd4d5229a9671.zip
Doxygen-f38608d4bec002a5051c860a599dd4d5229a9671.tar.gz
Doxygen-f38608d4bec002a5051c860a599dd4d5229a9671.tar.bz2
Release-1.1.3-20000522
Diffstat (limited to 'src/filename.cpp')
-rw-r--r--src/filename.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/filename.cpp b/src/filename.cpp
index 69646ec..6e1fa0a 100644
--- a/src/filename.cpp
+++ b/src/filename.cpp
@@ -55,7 +55,7 @@ void FileName::generateDiskNames()
//printf("Multiple occurrences of %s\n",name.data());
int i=0,j=0;
bool found=FALSE;
- while (!found)
+ while (!found) // search for the common prefix of all paths
{
fd=first();
while (fd && fd->isReference()) fd=next();
@@ -66,7 +66,7 @@ void FileName::generateDiskNames()
{
if (!fd->isReference())
{
- //printf("i=%d fd->path=`%s' fd->name=`%s'\n",i,fd->path.data(),fd->name().data());
+ //printf("i=%d j=%d fd->path=`%s' fd->name=`%s'\n",i,j,fd->path.left(i).data(),fd->name().data());
if (i==(int)fd->path.length())
{
//warning("Warning: Input file %s found multiple times!\n"
@@ -88,8 +88,9 @@ void FileName::generateDiskNames()
//printf("fd->setName(%s)\n",(fd->path.right(fd->path.length()-j-1)+name).data());
if (!fd->isReference())
{
- fd->setName(fd->path.right(fd->path.length()-j-1)+name);
- fd->diskname=convertSlashes(fd->name());
+ QCString prefix = fd->path.right(fd->path.length()-j-1);
+ fd->setName(prefix+name);
+ fd->diskname=convertSlashes(prefix+name);
}
fd=next();
}