mirror of
https://github.com/LMMS/lmms.git
synced 2026-05-17 11:18:30 -04:00
Use Canonical Paths for Relative Paths Calculations (#4211)
Fix redundant path elements Closes #4173
This commit is contained in:
@@ -1415,7 +1415,8 @@ QString SampleBuffer::tryToMakeRelative( const QString & file )
|
||||
{
|
||||
if( QFileInfo( file ).isRelative() == false )
|
||||
{
|
||||
QString f = QString( file ).replace( QDir::separator(), '/' );
|
||||
// Normalize the path
|
||||
QString f = QFileInfo( file ).canonicalFilePath().replace( QDir::separator(), '/' );
|
||||
|
||||
// First, look in factory samples
|
||||
// Isolate "samples/" from "data:/samples/"
|
||||
|
||||
Reference in New Issue
Block a user