From 140f3bd8846a085cbe395d15507c485627ead75c Mon Sep 17 00:00:00 2001 From: Rene Gollent Date: Mon, 12 Jul 2010 02:06:29 +0000 Subject: [PATCH] WellKnownEntry used a const char * to store the name of its entry, but didn't actually copy the passed-in string, only its pointer. Since the entries were all populated via strings off the stack, this led to them being overwritten with random garbage during program execution. In the best case, this would result in well known icons such as the ladybug boot volume failing to resolve. In the worst case, this likely led to random corruption/crashes. Fixed by having them store a BString instead. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37476 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/kits/tracker/FSUtils.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/kits/tracker/FSUtils.h b/src/kits/tracker/FSUtils.h index a52e60ecea..dd4a54c7ef 100644 --- a/src/kits/tracker/FSUtils.h +++ b/src/kits/tracker/FSUtils.h @@ -296,7 +296,7 @@ class WellKnowEntryList { node_ref node; directory_which which; - const char *name; + BString name; }; static directory_which Match(const node_ref *);