ASSERT: "!relative.contains("/")" in file /home/milian/projects/kde4/kdevelop/projectmanagers/cmake/cmakemanager.cpp, line 1038

Milian Wolff mail at milianw.de
Wed Oct 13 11:36:34 UTC 2010


On Wednesday 13 October 2010 13:19:41 Milian Wolff wrote:
> On Wednesday 13 October 2010 13:12:49 Milian Wolff wrote:
> > On Wednesday 13 October 2010 13:07:09 Milian Wolff wrote:
> > > hey aleix,
> > > 
> > > just triggered this assert by creating a new folder in cmake:
> > > 
> > > ASSERT: "!relative.contains("/")" in file
> > > /home/milian/projects/kde4/kdevelop/projectmanagers/cmake/cmakemanager.
> > > cp p, line 1038
> > > 
> > > since you changed this in 4.1 really make sure to fix this! It would be
> > > horrible to ship final with this!
> > 
> > ignore the corrupted things, I can reliably trigger this with master by
> > creating a folder in some subfolder:
> > 
> > kdevelop(30884)/kdevelop (cmake support debug) CMakeManager::addFolder:
> > Adding folder  KUrl("file:///home/development/projects/testbar/icons") 
> > to KUrl("file:///home/development/projects/testbar/icons/test")  as
> > "icons/test"
> 
> the folder url does not contain the trailing slash but that is required by
> KUrl::relativeUrl...
> 
> how should we fix this?

for the record: I've now enforced trailing slashes in FolderItems (setUrl 
overload, does not break bc or sc since FileItem already overloaded it).

This way we can safely do KUrl::relativeUrl(folder->url()) without falling in 
this trap again (I bet there are other places where this happened).

bye
-- 
Milian Wolff
mail at milianw.de
http://milianw.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20101013/a72a8b65/attachment.sig>


More information about the KDevelop-devel mailing list