From d3759373291c08d2cde93d85a76d190dc8a33830 Mon Sep 17 00:00:00 2001 From: zautrix Date: Mon, 11 Oct 2004 10:09:39 +0000 Subject: crash fix in saveAB --- (limited to 'kabc/addressbook.cpp') diff --git a/kabc/addressbook.cpp b/kabc/addressbook.cpp index ad0f702..19c26eb 100644 --- a/kabc/addressbook.cpp +++ b/kabc/addressbook.cpp @@ -632,9 +632,9 @@ bool AddressBook::saveAB() for ( it = manager->activeBegin(); it != manager->activeEnd(); ++it ) { qDebug("SaveAB::checking resource..." ); if ( (*it)->readOnly() ) - qDebug("readonly." ); + qDebug("resource is readonly." ); if ( (*it)->isOpen() ) - qDebug("open" ); + qDebug("resource is open" ); if ( !(*it)->readOnly() && (*it)->isOpen() ) { Ticket *ticket = requestSaveTicket( *it ); @@ -647,10 +647,11 @@ bool AddressBook::saveAB() //if ( !save( ticket ) ) if ( ticket->resource() ) { + QString name = ticket->resource()->resourceName(); if ( ! ticket->resource()->save( ticket ) ) ok = false; else - qDebug("StdAddressBook::saved '%s'", ticket->resource()->resourceName().latin1() ); + qDebug("StdAddressBook::resource saved '%s'", name.latin1() ); } else ok = false; -- cgit v0.9.0.2