[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

KDE 3.4.0 kpilot bug fixes



I have the experimental kde 3.4.0 packages installed.

I have recently corrected some bugs in kpilot (two involve data loss). The 
kpilot maintainer has committed the fixes to KDE HEAD, but KDE_3_4_0_BRANCH 
is not updated so it will be some time before they get into a release. It 
would be nice if they could go into the debian 3.4.0 kpilot package.

I attach a diff against the KDE_3_4_0_RELEASE cvs sources, hoping that will be 
useful. Here is a quick description of the bugs, in the order the fixes 
appear in the diff:

1. memofile conduit fails to create files for some memos sync'd from handheld 
(illegal characters in filenames)
2. todo conduit sometimes unnecessarily syncs unmodified korganizer todos to 
the handheld (the search for modified todos is incorrect)
3. calendar conduit fails to transfer some handheld events to korganizer (it 
incorrectly detects they already exist in the ical/vcal file)
4. calendar and todo conduits incorrectly flag events and todos as modified in 
the ical/vcal file after having sync'd them to the handheld
5. calendar conduit sometimes unnecessarily syncs unmodified korganizer events 
to the handheld (the search for modified events is incorrect)

Thanks
Philip Tuckey
diff -ur kpilot-KDE_3_4_0_RELEASE/conduits/memofileconduit/memofiles.cc kpilot/conduits/memofileconduit/memofiles.cc
--- kpilot-KDE_3_4_0_RELEASE/conduits/memofileconduit/memofiles.cc	2005-04-10 21:37:35.000000000 +0200
+++ kpilot/conduits/memofileconduit/memofiles.cc	2005-04-10 22:20:19.000000000 +0200
@@ -702,6 +702,8 @@
 			filename = CSL1("empty");
 		}
 	}
+	// Replace illegal characters in filename (this is incomplete)
+	filename.replace("/",CSL1("-"));
 
 	QString category = _categories[memo->getCat()];
 
diff -ur kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/todo-conduit.cc kpilot/conduits/vcalconduit/todo-conduit.cc
--- kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/todo-conduit.cc	2005-04-10 21:44:51.000000000 +0200
+++ kpilot/conduits/vcalconduit/todo-conduit.cc	2005-04-10 16:46:21.000000000 +0200
@@ -142,12 +142,12 @@
 	{
 		reading=true;
 		fAllTodosIterator = fAllTodos.begin();
-		if ( fAllTodosIterator != fAllTodos.end() ) e=*fAllTodosIterator;
 	}
 	else
 	{
 		++fAllTodosIterator;
 	}
+	if ( fAllTodosIterator != fAllTodos.end() ) e=*fAllTodosIterator;
 	while (fAllTodosIterator != fAllTodos.end() &&
 		e && e->syncStatus()!=KCal::Incidence::SYNCMOD)
 	{
diff -ur kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/vcal-conduitbase.cc kpilot/conduits/vcalconduit/vcal-conduitbase.cc
--- kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/vcal-conduitbase.cc	2005-04-10 21:47:36.000000000 +0200
+++ kpilot/conduits/vcalconduit/vcal-conduitbase.cc	2005-04-10 22:34:34.000000000 +0200
@@ -629,7 +629,7 @@
 
 	if (de)
 	{
-		e=fP->findIncidence(de);
+		e=fP->findIncidence(r->id());
 		if (!e)
 		{
 			// no corresponding entry found, so create, copy and insert it.
@@ -790,8 +790,8 @@
 //		r->setAttrib(r->getAttrib() & ~dlpRecAttrDeleted);
 		fLocalDatabase->writeRecord(r);
 //		fDatabase->writeRecord(r);
-		e->setSyncStatus(KCal::Incidence::SYNCNONE);
 		e->setPilotId(id);
+		e->setSyncStatus(KCal::Incidence::SYNCNONE);
 		KPILOT_DELETE(r);
 	}
 }
diff -ur kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/vcal-conduit.cc kpilot/conduits/vcalconduit/vcal-conduit.cc
--- kpilot-KDE_3_4_0_RELEASE/conduits/vcalconduit/vcal-conduit.cc	2005-04-10 21:49:39.000000000 +0200
+++ kpilot/conduits/vcalconduit/vcal-conduit.cc	2005-04-07 02:18:50.000000000 +0200
@@ -133,12 +133,12 @@
 	{
 		reading=true;
 		fAllEventsIterator = fAllEvents.begin();
-		if ( fAllEventsIterator != fAllEvents.end() ) e = *fAllEventsIterator;
 	}
 	else
 	{
 		++fAllEventsIterator;
 	}
+	if ( fAllEventsIterator != fAllEvents.end() ) e = *fAllEventsIterator;
 	while ( fAllEventsIterator != fAllEvents.end() &&
 		e && e->syncStatus()==KCal::Incidence::SYNCNONE && e->pilotId() > 0)
 	{

Reply to: