Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#254 closed defect (fixed)

QDir::cleanPath not working correctly

Reported by: rudi Owned by:
Priority: major Milestone: Qt 4.7
Component: QtCore Version:
Severity: low Keywords:
Cc:

Description

QDir::cleanPath("E:\\\\Qt\\\\4.7.3")

will give an unexpected result.

Attachments (2)

qdir.diff (403 bytes ) - added by rudi 13 years ago.
Workaround that keeps our changes
Captured2.png (60.9 KB ) - added by Dmitry A. Kuminov 13 years ago.

Download all attachments as: .zip

Change History (8)

comment:1 by Dmitry A. Kuminov, 13 years ago

Hmm, you basically reverted r1042 -) This is not correct; r1042 fixes a fundamental bug in Qt that cost me a lot of time to find and fix. Everything what is necessary in this case is to express that the path with the drive letter is not a network share, see r1084.

But thanks for noticing! It's a tiny regression of r1042.

P.S. The person who wrote QDir::cleanPath() should be seriously punished. I don't know how many hours you need to understand what exactly this code does. This task may be accomplished by a 10 times simpler function...

comment:2 by Dmitry A. Kuminov, 13 years ago

Resolution: fixed
Status: newclosed

comment:3 by rudi, 13 years ago

So we don't do something about the mentioned problem ?

QDir::cleanPath("E:\\\\Qt\\\\4.7.3") -> "e://Qt/4.7.3"

BTW, we see this in Creator's options dialog. When hovering the mouse over an given Qt Version, the source location in the popup window will express exactly this.

by rudi, 13 years ago

Attachment: qdir.diff added

Workaround that keeps our changes

comment:4 by rudi, 13 years ago

Resolution: fixed
Status: closedreopened

comment:5 by Dmitry A. Kuminov, 13 years ago

Resolution: fixed
Status: reopenedclosed

Hmm, didn't you rebuild your QtCore4.dll? The issue has been fixed by r1084.

qDebug() << QDir::cleanPath("E:\\\\Qt\\\\4.7.3")

prints

"E:/Qt/4.7.3"

here. And Qt Creator also works (see the attachment).

Last edited 13 years ago by Dmitry A. Kuminov (previous) (diff)

by Dmitry A. Kuminov, 13 years ago

Attachment: Captured2.png added

comment:6 by rudi, 13 years ago

You are right ! I had an issue here with the timestamp of a local modification...

Note: See TracTickets for help on using tickets.