[Kde-pim] Re: the path was never set before

Kevin Krammer kevin.krammer at gmx.at
Mon Jul 4 17:10:48 BST 2011


Hi Guy,

On Monday, 2011-07-04, Guy Maurel wrote:
> Hello Kevin!
> 
> On Wednesday, June 29, 2011 07:41:29 PM Kevin Krammer wrote:
> > Hi Guy,
> > 
> > On Wednesday, 2011-06-29, Guy Maurel wrote:
> > > Hello Kevin!
> > > 
> > > I have a problem with the mixedmaildirresource:
> > > 
> > > At the line mixedmaildirresource.cpp:88, there is an "if":
> > >   if ( ensureSaneConfiguration() ) {
> > > 
> > > This is a call of the method "bool
> > > 
> > > MixedMaildirResource::ensureSaneConfiguration()" which has an "if":
> > >   if ( Settings::self()->path().isEmpty() ) {
> > >   
> > >      const QString message = i18nc( "@info:status", "No usable storage
> > > 
> > > location configured."); kError() << message;
> > > 
> > >      status( Broken, message );
> > >      return false;
> > >   
> > >   }
> > > 
> > > I mean, the path was *never* set before, the return will be all the
> > > time "false".
> > 
> > Indeed, it is always false on first start because the resource has not
> > been configured yet.
> 
> the status is set to "Broken", look above.

Right, because without a directory to operate on it is broken.

> What happens after that? Is there any "reset" for the status?

In the migration scenario, the migrator configures the resource (see step (5) 
in my other email in this thread).

This results in MixedMaildirResource::reapplyConfiguration() to be called, 
which then should pass ensureSaneConfiguration().
It then calls synchronizeCollectionTree() which makes Akonadi server call 
MixedMaildirResource::retrieveCollections().
And there it sets the status to Running.

reapplyConfiguration() could of course set the status to Idle before calling 
synchronizeCollectionTree().Wouldn't hurt but would only be visible very 
briefly.

Cheers,
Kevin
-- 
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20110704/388e3caf/attachment.sig>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/


More information about the kde-pim mailing list