6th November 2022

Crashing J-Pilot

I am using J-Pilot since more than 20 years. I mostly use:

  1. Datebook as kind of a diary and for accounting purposes (what did I do for client X at date Y)
  2. Address
  3. Memos

I use Todo's rarely, if at all. I had used Todo's in the past a bit. For the Expense part: I just played with Expenses, but never used it for something essential.

I am currently changing J-Pilot, the Gtk3 based version, from the internal binary format to full SQLite format. See Possible Enhancements to J-Pilot and SQL Datamodel For J-Pilot.

Implementation reached completion, so testing old and new version side by side, to see whether I degraded anything. I observed bugs which have been present before I started my implementation. J-Pilot crashes under the following scenarios. Crash is

segmentation fault (core dumped)

1. In Address: When searching for names in addresses in the lower search bar, then J-Pilot crashes whenever I press the "Up" key. This crash is easy to reproduce. See search bar in below image, where I entered "abc".

This bug is not present in the Gtk2 version.

2. In Datebook: When cancelling changes in a repeating event, sometimes J-Pilot crashes, when one wants to ignore the conducted changes.

3. In To-Do: Clicking on "Completed" checkbox will eventually crash J-Pilot. Have not fully figured what the exact sequence is to reproduce it. But just creating a to-do entry, then copying it multiple times, then "completing" two or three of them will pretty soon lead to the crash.

Added 14-Nov-2022: When running in debug-mode, i.e., with command-line flag -d, then setting a yearly repeat will crash. Fixed with proper jp_logf() arguments, %d instead of %s. I guess this is above point 2.

Added 21-Nov-2022: When importing CSV into Datebook, which was previously exported by J-Pilot, the array repeatDays[] is not populated correctly in the case of repeatType == calendarRepeatNone. A check for end of string needs to be added in cb_dbook_import().

Added 22-Nov-2022: Quicksearch crash, i.e., above point 1, can be fixed by setting third agument to NULL in selectRecordAddressByRow() in address_gui.c.