Bug 250446

Summary: KNS3::Entry::installedFiles() prints wrong file address
Product: [Unmaintained] kdelibs Reporter: Peter ZHOU <peterzhoulei>
Component: knewstuffAssignee: Jeremy Whiting <jpwhiting>
Status: RESOLVED FIXED    
Severity: minor CC: alexander.lohnau, gladhorn
Priority: NOR    
Version First Reported In: 3.0   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Peter ZHOU 2010-09-07 14:03:59 UTC
Version:           3.0 (using KDE 4.4.2) 
OS:                Linux

it prints an additional "/" after the scripts installation dir

amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/string.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/script.spec" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/sites.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/main.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/lyrics.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/search.ui" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/.directory" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/json2.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.sr.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.ru.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.it.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.sr.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.it.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.cs.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.pt.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.lt.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.cs.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.fr.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.pt.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.lt.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.fr.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/.directory" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.es.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.es.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.de.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.de.qm" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/translations.pro" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/locale.ru.ts" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/translations/" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/cache.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/icons.qrc" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/patch.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/configure.ui" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/README" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/configure.js" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//ultimate_lyrics/" 
amarok:   [ScriptManager] "/home/peterzl/.kde/share/apps/amarok/scripts//"

Reproducible: Always
Comment 1 Christoph Feck 2010-09-07 14:16:34 UTC
This is not really a bug, "path//file" is the same as "path/file".

This allows faster concatenation of paths: You can just do PATH + "/b" without looking whether PATH has a trailing slash or not.

But knewstuff could normalize the paths before returning them.
Comment 2 Alexander Lohnau 2020-07-21 20:16:04 UTC
They are now normalized.