unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* doc-view warnings
@ 2007-11-16 16:52 Dan Nicolaescu
  2007-11-16 17:04 ` Tassilo Horn
  0 siblings, 1 reply; 3+ messages in thread
From: Dan Nicolaescu @ 2007-11-16 16:52 UTC (permalink / raw)
  To: emacs-devel


These might be bugs:

In doc-view-search-backward:
doc-view.el:790:20:Warning: reference to free variable `arg'

In doc-view-search:
doc-view.el:798:17:Warning: reference to free variable `arg'

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

* Re: doc-view warnings
  2007-11-16 16:52 doc-view warnings Dan Nicolaescu
@ 2007-11-16 17:04 ` Tassilo Horn
  2007-11-16 18:01   ` Dan Nicolaescu
  0 siblings, 1 reply; 3+ messages in thread
From: Tassilo Horn @ 2007-11-16 17:04 UTC (permalink / raw)
  To: emacs-devel

Dan Nicolaescu <dann@ics.uci.edu> writes:

Hi Dan!

> These might be bugs:
>
> In doc-view-search-backward:
> doc-view.el:790:20:Warning: reference to free variable `arg'
>
> In doc-view-search:
> doc-view.el:798:17:Warning: reference to free variable `arg'

Oh, yes, they are.  Here's the fix:

--8<---------------cut here---------------start------------->8---
2007-11-16  Tassilo Horn  <tassilo@member.fsf.org>

	* doc-view.el (doc-view-search-backward, doc-view-search): Fix
	assignment to free variable bug.
--8<---------------cut here---------------end--------------->8---

--8<---------------cut here---------------start------------->8---
Index: lisp/doc-view.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/doc-view.el,v
retrieving revision 1.22
diff -u -r1.22 doc-view.el
--- lisp/doc-view.el	16 Nov 2007 16:50:35 -0000	1.22
+++ lisp/doc-view.el	16 Nov 2007 17:04:02 -0000
@@ -787,7 +787,7 @@
   "Call `doc-view-search' for backward search.
 If prefix NEW-QUERY is given, ask for a new regexp."
   (interactive "P")
-  (doc-view-search arg t))
+  (doc-view-search new-query t))
 
 (defun doc-view-search (new-query &optional backward)
   "Jump to the next match or initiate a new search if NEW-QUERY is given.
@@ -795,7 +795,7 @@
 till now do that first.
 If BACKWARD is non-nil, jump to the previous match."
   (interactive "P")
-  (if (and (not arg)
+  (if (and (not new-query)
 	   doc-view-current-search-matches)
       (if backward
 	  (doc-view-search-previous-match 1)
--8<---------------cut here---------------end--------------->8---

Bye,
Tassilo

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

* Re: doc-view warnings
  2007-11-16 17:04 ` Tassilo Horn
@ 2007-11-16 18:01   ` Dan Nicolaescu
  0 siblings, 0 replies; 3+ messages in thread
From: Dan Nicolaescu @ 2007-11-16 18:01 UTC (permalink / raw)
  To: emacs-devel

Tassilo Horn <tassilo@member.fsf.org> writes:

  > Dan Nicolaescu <dann@ics.uci.edu> writes:
  > 
  > Hi Dan!
  > 
  > > These might be bugs:
  > >
  > > In doc-view-search-backward:
  > > doc-view.el:790:20:Warning: reference to free variable `arg'
  > >
  > > In doc-view-search:
  > > doc-view.el:798:17:Warning: reference to free variable `arg'
  > 
  > Oh, yes, they are.  Here's the fix:

Thanks, checked in.

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

end of thread, other threads:[~2007-11-16 18:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-16 16:52 doc-view warnings Dan Nicolaescu
2007-11-16 17:04 ` Tassilo Horn
2007-11-16 18:01   ` Dan Nicolaescu

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.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).