bug-mit-scheme
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #63534] Edwin crashes on certain buffer content


From: Taylor R. Campbell
Subject: [bug #63534] Edwin crashes on certain buffer content
Date: Thu, 15 Dec 2022 22:20:43 -0500 (EST)

URL:
  <https://savannah.gnu.org/bugs/?63534>

                 Summary: Edwin crashes on certain buffer content
                 Project: MIT/GNU Scheme
               Submitter: riastradh
               Submitted: Fri 16 Dec 2022 03:20:41 AM UTC
                Category: edwin
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Incorrect behavior
                  Status: None
                 Privacy: Public
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                Keywords: 


    _______________________________________________________

Follow-up Comments:


-------------------------------------------------------
Date: Fri 16 Dec 2022 03:20:41 AM UTC By: Taylor R. Campbell <riastradh>
Opening the attached bad.scm and typing C-x > to go to the end of the buffer
reliably, and apparently unrecoverably, crashes Edwin from master with the
following error:


;The object -3, passed as an argument to vector-8b-ref, is not the correct
type.
;To continue, call RESTART with an option number:
; (RESTART 3) => Return to the editor command loop.
; (RESTART 2) => Return to command level 2.
; (RESTART 1) => Return to read-eval-print level 1.
;package: (user)

3 error> (debug)

There are more than 50 subproblems on the stack.

Subproblem level: 0 (this is the lowest subproblem level)
Compiled code expression (from stack):
    (begin
     <!>
     (if (not (index-fixnum? index))
         (error:not-a index-fixnum? index 'vector-8b-ref))
     (if (not (less-than-fixnum? index (primitive-datum-ref string 1)))
         (error:bad-range-argument index 'vector-8b-ref))
     (primitive-byte-ref string (plus-fixnum byte0-index index)))
 subproblem being executed (marked by <!>):
    (if (not ((named-lambda (string? object) (or ... ... ...)) string))
        (error:not-a string? string 'vector-8b-ref))
Environment created by the procedure: VECTOR-8B-REF
 
 applied to: ("fffffffffffffffffffffffffffffffffffftttf" -3)
There is no execution history for this subproblem.
You are now in the debugger.  Type q to quit, ? for commands.

4 debug> h
SL#  Procedure-name          Expression

1.    vector-8b-ref           (begin (if (not ((named-lambda (string? object
...
1                            (eq? 116 (vector-8b-ref (%record-ref new-matri
...
2                            (begin (let ((full-line? (and (eq? xl 0) (eq? 
...
3    loop                    (let ((end-index* (or (next-specific-property-
...
4                            (begin (draw-region! window group start-index 
...
5                            (begin (generate-outlines window start end) (s
...
6    update-outlines!        (begin (%recache-window-buffer-local-variables
...
7    update-buffer-wi ...    (begin (if (vector-ref window 23) (update-over
...
8                            (and (or (not xi) ((named-lambda (clip-window-
...
9    :update-display!        (begin (update-inferior! (vector-ref window 8)
...
10                           (and (or (not xi) ((named-lambda (clip-window-
...
11   loop                    (and (update-inferior! (car inferiors) screen 
...
12                           (and (or (not xi) ((named-lambda (clip-window-
...
13   loop                    (and (update-inferior! (car inferiors) screen 
...
14   editor-frame-upd ...    (let ((finished? (window-update-display! windo
...
15                           (and (thunk) (if (memq (%record-ref screen 20)
...
16                           (let ((result (thunk))) (set! finished? result
...
17                           ;compiled code
18                           (let ((finished? ((%record-ref screen 14) scre
...
19                           ;compiled code
20   loop                    (and (update-screen! (car screens) display-sty
...
21   maybe-debug-sche ...    (begin (let ((p (%record-ref (or (name->variab
...
22                           ;compiled code
23                           (begin (if (let ((types (general-car-cdr frame
...
24                           (begin (signal-condition condition) (default-h
...
25                           (begin (handler continuation) (default-error-h
...
26                           (%record-ref #f 2)
27   loop                    ;compiled code
28                           (if (scroll-lines-up window start end y) (begi
...
29   update-outlines!        (begin (%recache-window-buffer-local-variables
...
30   update-buffer-wi ...    (begin (if (vector-ref window 23) (update-over
...
31                           (and (or (not xi) ((named-lambda (clip-window-
...
32   :update-display!        (begin (update-inferior! (vector-ref window 8)
...
33                           (and (or (not xi) ((named-lambda (clip-window-
...
34   loop                    (and (update-inferior! (car inferiors) screen 
...
35   editor-frame-upd ...    (let ((finished? (window-update-display! windo
...
36                           (and (thunk) (if (memq (%record-ref screen 20)
...
37                           (let ((result (thunk))) (set! finished? result
...
38                           ;compiled code
39                           (let ((finished? ((%record-ref screen 14) scre
...
40                           ;compiled code
41   loop                    (and (update-screen! (car screens) display-sty
...
42                           (begin (if (not (peek-no-hang 0)) (begin (if (
...
43   loop                    (let ((input (thunk))) (if (simple-event-handl
...
44   keyboard-read-1         (remap-alias-key (handle-simple-events (lambda
...
45   keyboard-read           (let ((key (keyboard-read-1 (%record-ref curre
...
46                           ;compiled code
47                           (let ((input (get-next-keyboard-char))) (if (i
...
48                           ;compiled code
49                           (begin (bind-abort-editor-command (lambda () (
...
50                           ;compiled code
51                           ;compiled code
52                           ;compiled code
53                           ;compiled code
54                           ;compiled code
55                           ;compiled code
56                           ;compiled code
57                           ;compiled code
58                           (begin (bind-condition-handler (cons condition
...
59                           ;compiled code
60                           ;compiled code
61   loop                    (loop (bind-abort-restart cmdl (lambda () (wit
...
62                           ;compiled code
63                           ;compiled code
64                           ;compiled code
65                           ;compiled code
66                           ;compiled code
67                           ;compiled code
68                           ;compiled code
69   map-1                   (begin (procedure (car l)) (map-1 (cdr l)))
70                           (begin (process-keyword (vector->list unused) 
...
71                           ;compiled code
72                           (begin (apply (car receivers) (cdr event)) (#[
...
73                           (begin (procedure item) (loop))
74                           ;compiled code
75   map-1                   (begin (procedure (car l)) (map-1 (cdr l)))
76                           ;compiled code
77                           (begin (unblock-thread-events) (ignore-errors 
...
78                           ;compiled code
79   loop                    (loop (bind-abort-restart cmdl (lambda () (wit
...
80                           ;compiled code
81                           ;compiled code
82                           ;compiled code

4 debug> u
Subproblem level: 1
Compiled code expression (from stack):
    (eq? 116 <!>)
 subproblem being executed (marked by <!>):
    (vector-8b-ref (%record-ref new-matrix 3) y)
Environment created by a LET special form
 
 applied to: (#t)
There is no execution history for this subproblem.

4 debug> a
----------------------------------------
Environment created by a LET special form
Depth (relative to initial environment): 0
 has bindings:

full-line? = #t


----------------------------------------
Environment created by a LET special form
Depth (relative to initial environment): 1
 has bindings:

new-matrix = #[matrix 12]


----------------------------------------
Environment created by the procedure: SCREEN-GET-OUTPUT-LINE
Depth (relative to initial environment): 2
 has bindings:

face = #f
screen = #[screen 13]
xl = 0
xu = 80
y = -3


----------------------------------------
Environment named: (edwin screen)
Depth (relative to initial environment): 3


----------------------------------------
Environment named: (edwin)
Depth (relative to initial environment): 4
         
         
----------------------------------------
Environment named: ()
Depth (relative to initial environment): 5

4 debug> g

Subproblem number (minimum 0): 26

Subproblem level: 26
Expression (from stack):
    (%record-ref #f 2)
There is no current environment.
There is no execution history for this subproblem.

4 debug> u
Subproblem level: 27
Compiled code expression unknown
#[compiled-return-address 14 ("bufwfs" #x6) #x1032 #x209c17a]
Environment created by the procedure: LOOP

 applied to: (#f 989 -3)
There is no execution history for this subproblem.

4 debug> a
----------------------------------------
Environment created by the procedure: LOOP
Depth (relative to initial environment): 0
 has bindings:

index = 989
new-start-y = -3
outline = #f


----------------------------------------
Environment created by a LET special form
Depth (relative to initial environment): 1
 has bindings:

amount = 29
start-outline = #[outline 15index: 14 y: 1]


----------------------------------------
Environment created by the procedure: SCROLL-LINES-UP
Depth (relative to initial environment): 2
 has bindings:

end = #[o3 16index: 1511 y: 38 #[outline 17index: 0 y: 1]]
new-start-y = -29
start = #[o3 18index: 0 y: 0 #[outline 15index: 14 y: 1]]
window = #0=#(#[class 19] #1=#(#[class 20] #2=#(#[class 21] #3=#(#[class 22
...


----------------------------------------
Environment named: (edwin window)
Depth (relative to initial environment): 3


----------------------------------------
Environment named: (edwin)
Depth (relative to initial environment): 4


----------------------------------------
Environment named: ()
Depth (relative to initial environment): 5

4 debug> 








    _______________________________________________________
File Attachments:


-------------------------------------------------------
Date: Fri 16 Dec 2022 03:20:41 AM UTC  Name: bad.scm  Size: 2KiB   By:
riastradh

<http://savannah.gnu.org/bugs/download.php?file_id=54107>

    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?63534>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]