Gnus development mailing list
 help / color / mirror / Atom feed
* the arglist of detect-coding-region is incompatible
@ 2001-09-27  5:19 Daiki Ueno
  2001-09-27 11:26 ` ShengHuo ZHU
  0 siblings, 1 reply; 2+ messages in thread
From: Daiki Ueno @ 2001-09-27  5:19 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 639 bytes --]

In *Summary*, when I type `1 g' to decode the article with the charset
input, I get an error:

>Wrong type argument: bufferp, t

The reason is that the argument list of the function
`detect-coding-region' is different between between Emacs and XEmacs.

Emacs:
detect-coding-region is a built-in function.
(detect-coding-region START END &optional HIGHEST)

XEmacs:
`detect-coding-region' is a built-in function
(detect-coding-region START END &optional BUFFER)

The attached patch fixes this.

2001-09-27   Daiki Ueno  <ueno@unixuser.org>

	* gnus-sum.el (gnus-summary-show-article): The arglist of
	detect-coding-region is incompatible.


[-- Attachment #2: gnus-sum.el.diff --]
[-- Type: application/octet-stream, Size: 759 bytes --]

Index: gnus-sum.el
===================================================================
RCS file: /usr/local/cvsroot/gnus/lisp/gnus-sum.el,v
retrieving revision 6.107
diff -u -F^( -r6.107 gnus-sum.el
--- gnus-sum.el	2001/09/24 17:35:24	6.107
+++ gnus-sum.el	2001/09/27 05:06:50
@@ -7821,7 +7821,10 @@ (defun gnus-summary-show-article (&optio
 		"View as charset: "
 		(save-excursion
 		  (set-buffer gnus-article-buffer)
-		  (detect-coding-region (point) (point-max) t)))))
+		  (let ((coding-systems
+			 (detect-coding-region (point) (point-max))))
+		    (or (car-safe coding-systems)
+			coding-systems))))))
 	  (gnus-newsgroup-ignored-charsets 'gnus-all))
       (gnus-summary-select-article nil 'force)
       (let ((deps gnus-newsgroup-dependencies)

[-- Attachment #3: Type: text/plain, Size: 16 bytes --]


-- 
Daiki Ueno

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

* Re: the arglist of detect-coding-region is incompatible
  2001-09-27  5:19 the arglist of detect-coding-region is incompatible Daiki Ueno
@ 2001-09-27 11:26 ` ShengHuo ZHU
  0 siblings, 0 replies; 2+ messages in thread
From: ShengHuo ZHU @ 2001-09-27 11:26 UTC (permalink / raw)


Daiki Ueno <ueno@unixuser.org> writes:

[...]

> The attached patch fixes this.
>
> 2001-09-27   Daiki Ueno  <ueno@unixuser.org>
>
> 	* gnus-sum.el (gnus-summary-show-article): The arglist of
> 	detect-coding-region is incompatible.

Thanks for your patch. I've installed it.

ShengHuo



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

end of thread, other threads:[~2001-09-27 11:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-09-27  5:19 the arglist of detect-coding-region is incompatible Daiki Ueno
2001-09-27 11:26 ` ShengHuo ZHU

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 NNTP newsgroup(s).