* [PATCH] Ignore encrypted parts when indexing.
@ 2011-12-27 17:11 Jameson Graef Rollins
2011-12-28 3:31 ` Austin Clements
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Jameson Graef Rollins @ 2011-12-27 17:11 UTC (permalink / raw)
To: Notmuch Mail
It appears to be an oversight that encrypted parts were indexed
previously. The terms generated from encrypted parts are meaningless
and do nothing but add bloat to the database. It is not worth
indexing the encrypted content, just as it's not worth indexing the
signatures in signed parts.
---
lib/index.cc | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/lib/index.cc b/lib/index.cc
index e8e9922..0cff9cd 100644
--- a/lib/index.cc
+++ b/lib/index.cc
@@ -339,6 +339,10 @@ _index_mime_part (notmuch_message_t *message,
if (i > 1)
fprintf (stderr, "Warning: Unexpected extra parts of multipart/signed. Indexing anyway.\n");
}
+ if (GMIME_IS_MULTIPART_ENCRYPTED (multipart)) {
+ /* Don't index encrypted parts. */
+ continue
+ }
_index_mime_part (message,
g_mime_multipart_get_part (multipart, i));
}
--
1.7.7.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] Ignore encrypted parts when indexing.
2011-12-27 17:11 [PATCH] Ignore encrypted parts when indexing Jameson Graef Rollins
@ 2011-12-28 3:31 ` Austin Clements
2011-12-28 12:40 ` Xavier Maillard
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
2 siblings, 0 replies; 7+ messages in thread
From: Austin Clements @ 2011-12-28 3:31 UTC (permalink / raw)
To: Jameson Graef Rollins; +Cc: Notmuch Mail
Quoth Jameson Graef Rollins on Dec 27 at 9:11 am:
> It appears to be an oversight that encrypted parts were indexed
> previously. The terms generated from encrypted parts are meaningless
> and do nothing but add bloat to the database. It is not worth
> indexing the encrypted content, just as it's not worth indexing the
> signatures in signed parts.
> ---
> lib/index.cc | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/lib/index.cc b/lib/index.cc
> index e8e9922..0cff9cd 100644
> --- a/lib/index.cc
> +++ b/lib/index.cc
> @@ -339,6 +339,10 @@ _index_mime_part (notmuch_message_t *message,
> if (i > 1)
> fprintf (stderr, "Warning: Unexpected extra parts of multipart/signed. Indexing anyway.\n");
> }
> + if (GMIME_IS_MULTIPART_ENCRYPTED (multipart)) {
> + /* Don't index encrypted parts. */
> + continue
Uh. Semicolon?
> + }
> _index_mime_part (message,
> g_mime_multipart_get_part (multipart, i));
> }
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] Ignore encrypted parts when indexing.
2011-12-27 17:11 [PATCH] Ignore encrypted parts when indexing Jameson Graef Rollins
2011-12-28 3:31 ` Austin Clements
@ 2011-12-28 12:40 ` Xavier Maillard
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
2 siblings, 0 replies; 7+ messages in thread
From: Xavier Maillard @ 2011-12-28 12:40 UTC (permalink / raw)
To: Jameson Graef Rollins, Notmuch Mail
Hi Jameson,
On Tue, 27 Dec 2011 09:11:41 -0800, Jameson Graef Rollins <jrollins@finestructure.net> wrote:
> It appears to be an oversight that encrypted parts were indexed
> previously. The terms generated from encrypted parts are meaningless
> and do nothing but add bloat to the database. It is not worth
> indexing the encrypted content, just as it's not worth indexing the
> signatures in signed parts.
+1 for this.
But,
> + if (GMIME_IS_MULTIPART_ENCRYPTED (multipart)) {
> + /* Don't index encrypted parts. */
> + continue
This needs a semicolon, doesn't it ?
/Xavier
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH v2] Ignore encrypted parts when indexing.
2011-12-27 17:11 [PATCH] Ignore encrypted parts when indexing Jameson Graef Rollins
2011-12-28 3:31 ` Austin Clements
2011-12-28 12:40 ` Xavier Maillard
@ 2011-12-28 20:14 ` Jameson Graef Rollins
2011-12-28 20:36 ` Austin Clements
` (2 more replies)
2 siblings, 3 replies; 7+ messages in thread
From: Jameson Graef Rollins @ 2011-12-28 20:14 UTC (permalink / raw)
To: Notmuch Mail
It appears to be an oversight that encrypted parts were indexed
previously. The terms generated from encrypted parts are meaningless
and do nothing but add bloat to the database. It is not worth
indexing the encrypted content, just as it's not worth indexing the
signatures in signed parts.
---
Fixes missing colon. Thanks Austin, Xavier.
lib/index.cc | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/lib/index.cc b/lib/index.cc
index e8e9922..d8f8b2b 100644
--- a/lib/index.cc
+++ b/lib/index.cc
@@ -339,6 +339,10 @@ _index_mime_part (notmuch_message_t *message,
if (i > 1)
fprintf (stderr, "Warning: Unexpected extra parts of multipart/signed. Indexing anyway.\n");
}
+ if (GMIME_IS_MULTIPART_ENCRYPTED (multipart)) {
+ /* Don't index encrypted parts. */
+ continue;
+ }
_index_mime_part (message,
g_mime_multipart_get_part (multipart, i));
}
--
1.7.7.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH v2] Ignore encrypted parts when indexing.
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
@ 2011-12-28 20:36 ` Austin Clements
2011-12-28 21:53 ` Tomi Ollila
2011-12-29 22:07 ` David Bremner
2 siblings, 0 replies; 7+ messages in thread
From: Austin Clements @ 2011-12-28 20:36 UTC (permalink / raw)
To: Jameson Graef Rollins; +Cc: Notmuch Mail
LGTM.
Quoth Jameson Graef Rollins on Dec 28 at 12:14 pm:
> It appears to be an oversight that encrypted parts were indexed
> previously. The terms generated from encrypted parts are meaningless
> and do nothing but add bloat to the database. It is not worth
> indexing the encrypted content, just as it's not worth indexing the
> signatures in signed parts.
> ---
> Fixes missing colon. Thanks Austin, Xavier.
>
> lib/index.cc | 4 ++++
> 1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/lib/index.cc b/lib/index.cc
> index e8e9922..d8f8b2b 100644
> --- a/lib/index.cc
> +++ b/lib/index.cc
> @@ -339,6 +339,10 @@ _index_mime_part (notmuch_message_t *message,
> if (i > 1)
> fprintf (stderr, "Warning: Unexpected extra parts of multipart/signed. Indexing anyway.\n");
> }
> + if (GMIME_IS_MULTIPART_ENCRYPTED (multipart)) {
> + /* Don't index encrypted parts. */
> + continue;
> + }
> _index_mime_part (message,
> g_mime_multipart_get_part (multipart, i));
> }
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] Ignore encrypted parts when indexing.
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
2011-12-28 20:36 ` Austin Clements
@ 2011-12-28 21:53 ` Tomi Ollila
2011-12-29 22:07 ` David Bremner
2 siblings, 0 replies; 7+ messages in thread
From: Tomi Ollila @ 2011-12-28 21:53 UTC (permalink / raw)
To: Jameson Graef Rollins, Notmuch Mail
On Wed, 28 Dec 2011 12:14:29 -0800, Jameson Graef Rollins <jrollins@finestructure.net> wrote:
> It appears to be an oversight that encrypted parts were indexed
> previously. The terms generated from encrypted parts are meaningless
> and do nothing but add bloat to the database. It is not worth
> indexing the encrypted content, just as it's not worth indexing the
> signatures in signed parts.
> ---
LGTM.
Tomi
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH v2] Ignore encrypted parts when indexing.
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
2011-12-28 20:36 ` Austin Clements
2011-12-28 21:53 ` Tomi Ollila
@ 2011-12-29 22:07 ` David Bremner
2 siblings, 0 replies; 7+ messages in thread
From: David Bremner @ 2011-12-29 22:07 UTC (permalink / raw)
To: Jameson Graef Rollins, Notmuch Mail
On Wed, 28 Dec 2011 12:14:29 -0800, Jameson Graef Rollins <jrollins@finestructure.net> wrote:
> It appears to be an oversight that encrypted parts were indexed
> previously. The terms generated from encrypted parts are meaningless
> and do nothing but add bloat to the database. It is not worth
> indexing the encrypted content, just as it's not worth indexing the
> signatures in signed parts.
Pushed.
d
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2011-12-29 22:07 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-27 17:11 [PATCH] Ignore encrypted parts when indexing Jameson Graef Rollins
2011-12-28 3:31 ` Austin Clements
2011-12-28 12:40 ` Xavier Maillard
2011-12-28 20:14 ` [PATCH v2] " Jameson Graef Rollins
2011-12-28 20:36 ` Austin Clements
2011-12-28 21:53 ` Tomi Ollila
2011-12-29 22:07 ` David Bremner
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).