From 9f5809d921f3380c36f482e66184039ec0b0ea93 Mon Sep 17 00:00:00 2001 From: Shane Kearns Date: Fri, 10 Jun 2011 19:23:55 +0100 Subject: Symbian QFileSystemWatcher: fix potential crash An address on the stack was being passed to an asynchronous API. This is changed to use the copy of the data on the heap. Reviewed-by: joao --- src/corelib/io/qfilesystemwatcher_symbian.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/corelib/io/qfilesystemwatcher_symbian.cpp b/src/corelib/io/qfilesystemwatcher_symbian.cpp index 6e5e911..63cc4f1 100644 --- a/src/corelib/io/qfilesystemwatcher_symbian.cpp +++ b/src/corelib/io/qfilesystemwatcher_symbian.cpp @@ -62,9 +62,9 @@ QNotifyChangeEvent::QNotifyChangeEvent(RFs &fs, const TDesC &file, failureCount(0) { if (isDir) { - fsSession.NotifyChange(ENotifyEntry, iStatus, file); + fsSession.NotifyChange(ENotifyEntry, iStatus, watchedPath); } else { - fsSession.NotifyChange(ENotifyAll, iStatus, file); + fsSession.NotifyChange(ENotifyAll, iStatus, watchedPath); } CActiveScheduler::Add(this); SetActive(); -- cgit v0.12