Merge #138: Fix crash when searching by date

It seems Xapian returns query descriptions containing non-UTF8 characters
(binary?) when creating queries for dates. This patch uses a default string
when logging the generated query.

Fixes #138

Squashed commit of the following:

commit e5516bd4c0f173848e5455df50208a31c23d35e8
Author: Eric Weikl <eric.weikl@gmx.net>
Date:   Sun Sep 8 13:05:35 2013 +0200

    fix copy&paste

commit 3293a251cad53586bb4d71af0b20e751b8b6e36e
Author: Eric Weikl <eric.weikl@gmx.net>
Date:   Sun Sep 1 17:03:41 2013 +0200

    Fix crash when searching by date

    It seems Xapian returns query descriptions containing non-UTF8 characters
    (binary?) when creating queries for dates. This patch uses a default string
    when logging the generated query.

    Fixes #138
Merge #151: Fix encoding on all fields of message in thread view

Squashed commit of the following:

commit 9c27a75da568390d1a3ab5fa81a42978fafd4804
Author: Gaute Hope <eg@gaute.vetsj.com>
Date:   Sat Sep 28 18:51:25 2013 +0200

    on :open as well

commit c4a778219a3e88cbc5cc4e15cfab4c6d2e6f7c40
Author: Gaute Hope <eg@gaute.vetsj.com>
Date:   Sat Sep 28 18:32:01 2013 +0200

    Fix encoding on all fields in the :closed message in a thread view
rescue to fix_encoding when writing message fails due to encoding errors
Make sure m.snippet is not nil before trying to fix_encoding!
Merge #148: Fallback to fix_encoding! when writing message body parts fail
Merge branch 'sup-heliotrope/develop' into maildir-sync