unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH v1 1/2] notmuch: Silence compiler warnings.
@ 2018-10-04  9:45 David Edmondson
  2018-10-04  9:45 ` [PATCH v1 2/2] emacs: Update integration with third party packages David Edmondson
  0 siblings, 1 reply; 5+ messages in thread
From: David Edmondson @ 2018-10-04  9:45 UTC (permalink / raw)
  To: notmuch

---
 debugger.c           | 7 ++++---
 gmime-filter-reply.c | 4 ++--
 lib/index.cc         | 3 ++-
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/debugger.c b/debugger.c
index 5cb38ac4..db258c33 100644
--- a/debugger.c
+++ b/debugger.c
@@ -31,13 +31,14 @@
 bool
 debugger_is_active (void)
 {
-    char buf[1024];
+    char proc[PATH_MAX];
+    char buf[PATH_MAX];
 
     if (RUNNING_ON_VALGRIND)
 	return true;
 
-    sprintf (buf, "/proc/%d/exe", getppid ());
-    if (readlink (buf, buf, sizeof (buf)) != -1 &&
+    sprintf (proc, "/proc/%d/exe", getppid ());
+    if (readlink (proc, buf, sizeof (buf)) != -1 &&
 	strncmp (basename (buf), "gdb", 3) == 0)
     {
 	return true;
diff --git a/gmime-filter-reply.c b/gmime-filter-reply.c
index f673c0a2..5a956395 100644
--- a/gmime-filter-reply.c
+++ b/gmime-filter-reply.c
@@ -29,7 +29,7 @@
  **/
 
 
-static void g_mime_filter_reply_class_init (GMimeFilterReplyClass *klass);
+static void g_mime_filter_reply_class_init (GMimeFilterReplyClass *klass, gpointer klass_data);
 static void g_mime_filter_reply_init (GMimeFilterReply *filter, GMimeFilterReplyClass *klass);
 static void g_mime_filter_reply_finalize (GObject *object);
 
@@ -70,7 +70,7 @@ g_mime_filter_reply_get_type (void)
 
 
 static void
-g_mime_filter_reply_class_init (GMimeFilterReplyClass *klass)
+g_mime_filter_reply_class_init (GMimeFilterReplyClass *klass, gpointer klass_data __attribute__ ((unused)))
 {
 	GObjectClass *object_class = G_OBJECT_CLASS (klass);
 	GMimeFilterClass *filter_class = GMIME_FILTER_CLASS (klass);
diff --git a/lib/index.cc b/lib/index.cc
index 3f694387..86c6171d 100644
--- a/lib/index.cc
+++ b/lib/index.cc
@@ -142,7 +142,8 @@ static void filter_reset (GMimeFilter *filter);
 static GMimeFilterClass *parent_class = NULL;
 
 static void
-notmuch_filter_discard_non_term_class_init (NotmuchFilterDiscardNonTermClass *klass)
+notmuch_filter_discard_non_term_class_init (NotmuchFilterDiscardNonTermClass *klass,
+					    gpointer klass_data __attribute__ ((unused)))
 {
     GObjectClass *object_class = G_OBJECT_CLASS (klass);
     GMimeFilterClass *filter_class = GMIME_FILTER_CLASS (klass);
-- 
2.19.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v1 2/2] emacs: Update integration with third party packages.
  2018-10-04  9:45 [PATCH v1 1/2] notmuch: Silence compiler warnings David Edmondson
@ 2018-10-04  9:45 ` David Edmondson
  2018-10-04 21:16   ` Tomi Ollila
  2018-10-08 15:52   ` David Bremner
  0 siblings, 2 replies; 5+ messages in thread
From: David Edmondson @ 2018-10-04  9:45 UTC (permalink / raw)
  To: notmuch

`mm-inline-text-html-with-images' was removed from mm-decode.el in
2016 and replaced with `mm-html-inhibit-images'.

`gnus-select-frame-set-input-focus' was removed from gnus-util.el in
2016 and existed only for XEmacs compatibility.
---
 emacs/notmuch-mua.el  | 2 +-
 emacs/notmuch-show.el | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
index df2ac447..e205fa4c 100644
--- a/emacs/notmuch-mua.el
+++ b/emacs/notmuch-mua.el
@@ -306,7 +306,7 @@ modified. This function is notmuch addaptation of
 	  (if window
 	      ;; Raise the frame already displaying the message buffer.
 	      (progn
-		(gnus-select-frame-set-input-focus (window-frame window))
+		(select-frame-set-input-focus (window-frame window))
 		(select-window window))
 	    (funcall switch-function buffer)
 	    (set-buffer buffer))
diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
index a0a58373..78f1af47 100644
--- a/emacs/notmuch-show.el
+++ b/emacs/notmuch-show.el
@@ -604,7 +604,7 @@ will return nil if the CID is unknown or cannot be retrieved."
     (unless (assq 'notmuch-show-mode w3m-cid-retrieve-function-alist)
       (push (cons 'notmuch-show-mode #'notmuch-show--cid-w3m-retrieve)
 	    w3m-cid-retrieve-function-alist)))
-  (setq mm-inline-text-html-with-images t))
+  (setq mm-html-inhibit-images nil))
 
 (defvar w3m-current-buffer) ;; From `w3m.el'.
 (defun notmuch-show--cid-w3m-retrieve (url &rest args)
-- 
2.19.0

^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v1 2/2] emacs: Update integration with third party packages.
  2018-10-04  9:45 ` [PATCH v1 2/2] emacs: Update integration with third party packages David Edmondson
@ 2018-10-04 21:16   ` Tomi Ollila
  2018-10-04 21:38     ` David Edmondson
  2018-10-08 15:52   ` David Bremner
  1 sibling, 1 reply; 5+ messages in thread
From: Tomi Ollila @ 2018-10-04 21:16 UTC (permalink / raw)
  To: David Edmondson, notmuch

On Thu, Oct 04 2018, David Edmondson wrote:

> `mm-inline-text-html-with-images' was removed from mm-decode.el in
> 2016 and replaced with `mm-html-inhibit-images'.
>
> `gnus-select-frame-set-input-focus' was removed from gnus-util.el in
> 2016 and existed only for XEmacs compatibility.

2/2 looks good to me

1/2 is IMO okayish (but ymmv); i personally don't like
__attribute__((unused)) as it is effectively the same as (void)var (neither
notices the case when variable is actually used) also, 1/2 is farther
away to fit onto 80 column terminal window ;/

Tomi


> ---
>  emacs/notmuch-mua.el  | 2 +-
>  emacs/notmuch-show.el | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
> index df2ac447..e205fa4c 100644
> --- a/emacs/notmuch-mua.el
> +++ b/emacs/notmuch-mua.el
> @@ -306,7 +306,7 @@ modified. This function is notmuch addaptation of
>  	  (if window
>  	      ;; Raise the frame already displaying the message buffer.
>  	      (progn
> -		(gnus-select-frame-set-input-focus (window-frame window))
> +		(select-frame-set-input-focus (window-frame window))
>  		(select-window window))
>  	    (funcall switch-function buffer)
>  	    (set-buffer buffer))
> diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
> index a0a58373..78f1af47 100644
> --- a/emacs/notmuch-show.el
> +++ b/emacs/notmuch-show.el
> @@ -604,7 +604,7 @@ will return nil if the CID is unknown or cannot be retrieved."
>      (unless (assq 'notmuch-show-mode w3m-cid-retrieve-function-alist)
>        (push (cons 'notmuch-show-mode #'notmuch-show--cid-w3m-retrieve)
>  	    w3m-cid-retrieve-function-alist)))
> -  (setq mm-inline-text-html-with-images t))
> +  (setq mm-html-inhibit-images nil))
>  
>  (defvar w3m-current-buffer) ;; From `w3m.el'.
>  (defun notmuch-show--cid-w3m-retrieve (url &rest args)
> -- 
> 2.19.0
>
> _______________________________________________
> notmuch mailing list
> notmuch@notmuchmail.org
> https://notmuchmail.org/mailman/listinfo/notmuch

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1 2/2] emacs: Update integration with third party packages.
  2018-10-04 21:16   ` Tomi Ollila
@ 2018-10-04 21:38     ` David Edmondson
  0 siblings, 0 replies; 5+ messages in thread
From: David Edmondson @ 2018-10-04 21:38 UTC (permalink / raw)
  To: Tomi Ollila, notmuch

On Friday, 2018-10-05 at 00:16:58 +03, Tomi Ollila wrote:

> On Thu, Oct 04 2018, David Edmondson wrote:
>
>> `mm-inline-text-html-with-images' was removed from mm-decode.el in
>> 2016 and replaced with `mm-html-inhibit-images'.
>>
>> `gnus-select-frame-set-input-focus' was removed from gnus-util.el in
>> 2016 and existed only for XEmacs compatibility.
>
> 2/2 looks good to me

Thanks.

> 1/2 is IMO okayish (but ymmv); i personally don't like
> __attribute__((unused)) as it is effectively the same as (void)var (neither
> notices the case when variable is actually used) also,

I don't have a strong opinion, but it's the house style.

> 1/2 is farther
> away to fit onto 80 column terminal window ;/

Similarly, I tried to stay similar to existing code (which is why one is
wrapped and the other is not).

> Tomi
>
>
>> ---
>>  emacs/notmuch-mua.el  | 2 +-
>>  emacs/notmuch-show.el | 2 +-
>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>
>> diff --git a/emacs/notmuch-mua.el b/emacs/notmuch-mua.el
>> index df2ac447..e205fa4c 100644
>> --- a/emacs/notmuch-mua.el
>> +++ b/emacs/notmuch-mua.el
>> @@ -306,7 +306,7 @@ modified. This function is notmuch addaptation of
>>  	  (if window
>>  	      ;; Raise the frame already displaying the message buffer.
>>  	      (progn
>> -		(gnus-select-frame-set-input-focus (window-frame window))
>> +		(select-frame-set-input-focus (window-frame window))
>>  		(select-window window))
>>  	    (funcall switch-function buffer)
>>  	    (set-buffer buffer))
>> diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el
>> index a0a58373..78f1af47 100644
>> --- a/emacs/notmuch-show.el
>> +++ b/emacs/notmuch-show.el
>> @@ -604,7 +604,7 @@ will return nil if the CID is unknown or cannot be retrieved."
>>      (unless (assq 'notmuch-show-mode w3m-cid-retrieve-function-alist)
>>        (push (cons 'notmuch-show-mode #'notmuch-show--cid-w3m-retrieve)
>>  	    w3m-cid-retrieve-function-alist)))
>> -  (setq mm-inline-text-html-with-images t))
>> +  (setq mm-html-inhibit-images nil))
>>  
>>  (defvar w3m-current-buffer) ;; From `w3m.el'.
>>  (defun notmuch-show--cid-w3m-retrieve (url &rest args)
>> -- 
>> 2.19.0
>>
>> _______________________________________________
>> notmuch mailing list
>> notmuch@notmuchmail.org
>> https://notmuchmail.org/mailman/listinfo/notmuch

dme.
-- 
Tell me sweet little lies.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v1 2/2] emacs: Update integration with third party packages.
  2018-10-04  9:45 ` [PATCH v1 2/2] emacs: Update integration with third party packages David Edmondson
  2018-10-04 21:16   ` Tomi Ollila
@ 2018-10-08 15:52   ` David Bremner
  1 sibling, 0 replies; 5+ messages in thread
From: David Bremner @ 2018-10-08 15:52 UTC (permalink / raw)
  To: David Edmondson, notmuch

David Edmondson <dme@dme.org> writes:

> `mm-inline-text-html-with-images' was removed from mm-decode.el in
> 2016 and replaced with `mm-html-inhibit-images'.
>
> `gnus-select-frame-set-input-focus' was removed from gnus-util.el in
> 2016 and existed only for XEmacs compatibility.

pushed to master

d

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-10-08 15:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-04  9:45 [PATCH v1 1/2] notmuch: Silence compiler warnings David Edmondson
2018-10-04  9:45 ` [PATCH v1 2/2] emacs: Update integration with third party packages David Edmondson
2018-10-04 21:16   ` Tomi Ollila
2018-10-04 21:38     ` David Edmondson
2018-10-08 15:52   ` 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).