GNOME Bugzilla – Bug 581282
Planner crashes when click on "Print Preview" and the project is empty
Last modified: 2013-04-29 07:06:27 UTC
When someone open Planner 0.14.4 and source code repository, and make click on "Print Preview" the program crashes. I test in Windows (binary) Linux (Debian repositories) and Freebsd (ports) versions, and I also compile the program from the oficial tarball and svn version.
Created attachment 133914 [details] [review] Temporarily Fix This is a little patch that prevent the application crashes when in an empty project selects "print preview"
I can confirm this problem. The above patch isn't a real solution, we'll need to investigate this.
Comment on attachment 133914 [details] [review] Temporarily Fix Not an appropriate solution.
I think showing an empty page in this case could reduce the severity of the bug from critical to normal. At least there is no better solution proposed yet during a year.
Created attachment 216048 [details] [review] One the possible solution for the problem
gtk_print_operation_set_n_pages documentation says that n_pages "must be set to a positive number before the rendering starts". So setting it to 0 in your patch won't work. Please follow the patch submission guidelines in the future, as patches need to be in a specific format: http://live.gnome.org/GnomeLove/SubmittingPatches
Created attachment 238551 [details] [review] Don't crash on an empty print preview, just provide an empty preview.
Comment on attachment 238551 [details] [review] Don't crash on an empty print preview, just provide an empty preview. Please push this and close the bug afterwards.
Attachment 238551 [details] pushed as 0cc65e2 - Don't crash on an empty print preview, just provide an empty preview.
*** Bug 699179 has been marked as a duplicate of this bug. ***