Commit 5cab6598 authored by Scott Wheeler's avatar Scott Wheeler

This way works. ;-) KStandardDirs::realPath() only works for directories

(though I don't see why it was coded to just work with directories), so
here I'm using the C API.

svn path=/trunk/kdemultimedia/juk/; revision=211897
parent 5dd1bf6a
......@@ -37,6 +37,7 @@
#include <qclipboard.h>
#include <stdlib.h>
#include <limits.h>
#include <time.h>
#include "playlist.h"
......@@ -456,18 +457,11 @@ bool Playlist::isColumnVisible(int c) const
QString Playlist::resolveSymLinks(const QFileInfo &file)
return file.absFilePath();
else {
QString linkFileName = file.readLink();
QFileInfo linkFile;
linkFile.setFile(file.dirPath(true) + QDir::separator() + linkFileName);
return linkFile.absFilePath();
char real[PATH_MAX];
if(file.exists() && realpath(QFile::encodeName(file.absFilePath()).data(), real))
return QFile::decodeName(real);
return QString::null;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment