In `repeat-complex-command', range check the argument correctly.
authorChris Hanson <org/chris-hanson/cph>
Sun, 23 Apr 1989 23:24:49 +0000 (23:24 +0000)
committerChris Hanson <org/chris-hanson/cph>
Sun, 23 Apr 1989 23:24:49 +0000 (23:24 +0000)
v7/src/edwin/prompt.scm

index 4c856ccdfe835ab83bd0329b5284a25c37298a21..a98d65a0b05e7c8881ff66d82ca7632af4b87724 100644 (file)
@@ -1,6 +1,6 @@
 ;;; -*-Scheme-*-
 ;;;
-;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/prompt.scm,v 1.132 1989/04/20 08:16:22 cph Exp $
+;;;    $Header: /Users/cph/tmp/foo/mit-scheme/mit-scheme/v7/src/edwin/prompt.scm,v 1.133 1989/04/23 23:24:49 cph Exp $
 ;;;
 ;;;    Copyright (c) 1986, 1989 Massachusetts Institute of Technology
 ;;;
@@ -631,7 +631,8 @@ Whilst editing the command, the following commands are available:
   (lambda (argument)
     (fluid-let ((*command-history* (command-history-list))
                (*command-history-index* argument))
-      (if (not (< 0 argument (length *command-history*)))
+      (if (or (<= argument 0)
+             (> argument (length *command-history*)))
          (editor-error "argument out of range: " argument))
       (execute-command-history-entry
        (read-from-string