~ubuntu-branches/ubuntu/trusty/kdepimlibs/trusty

« back to all changes in this revision

Viewing changes to akonadi/session.cpp

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell
  • Date: 2014-04-10 21:53:31 UTC
  • mfrom: (1.1.112)
  • Revision ID: package-import@ubuntu.com-20140410215331-4skq50lp0ru1pdxo
Tags: 4:4.13.0-0ubuntu1
New upstream KDE Software Compilation release

Show diffs side-by-side

added added

removed removed

Lines of Context:
358
358
 
359
359
void SessionPrivate::serverStateChanged( ServerManager::State state )
360
360
{
361
 
  if ( state == ServerManager::Running && !connected )
 
361
  if ( state == ServerManager::Running && !connected ) {
362
362
    reconnect();
 
363
  } else if ( !connected && state == ServerManager::Broken ) {
 
364
    // If the server is broken, cancel all pending jobs, otherwise they will be
 
365
    // blocked forever and applications waiting for them to finish would be stuck
 
366
    Q_FOREACH ( Job *job, queue ) {
 
367
      job->setError( Job::ConnectionFailed );
 
368
      job->kill( KJob::EmitResult );
 
369
    }
 
370
  }
363
371
}
364
372
 
365
373
void SessionPrivate::itemRevisionChanged( Akonadi::Item::Id itemId, int oldRevision, int newRevision )