bug-zile
[Top][All Lists]
Advanced

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

[Bug-zile] Segmentation fault in F_find_alternate_file


From: Ulrich Mueller
Subject: [Bug-zile] Segmentation fault in F_find_alternate_file
Date: Sat, 4 Jul 2009 12:09:49 +0200

Zile crashes if one types C-x C-v in a buffer with no associated file.
To reproduce:

1. Start zile
2. Type C-x C-v immediately

GDB backtrace is included below.

Ulrich


Program received signal SIGSEGV, Segmentation fault.
_______________________________________________________________________________
     eax:00000000 ebx:77E8EFF4  ecx:77E74AAC  edx:0805FB5A     eflags:00010202
     esi:08063520 edi:00000000  esp:7F818DF8  ebp:7F818E08     eip:08061B2D
     cs:0073  ds:007B  es:007B  fs:0000  gs:0033  ss:007B    o d I t s z a p c 
[007B:7F818DF8]---------------------------------------------------------[stack]
7F818E28 : 38 8E 81 7F  8B 18 06 08 - 30 C0 F6 08  E8 09 F7 08 8.......0.......
7F818E18 : 01 00 00 00  BD 9D 04 08 - C0 FF F7 08  F8 11 F7 08 ................
7F818E08 : 38 8E 81 7F  80 1B 06 08 - 00 00 00 00  30 C0 F6 08 8...........0...
7F818DF8 : 08 8E 81 7F  00 00 00 00 - 30 C0 F6 08  F8 11 F7 00 ........0.......
[007B:08063520]---------------------------------------------------------[ data]
08063520 : 55 89 E5 57  56 53 E8 4D - 00 00 00 81  C3 C9 9A 00 U..WVS.M........
08063530 : 00 83 EC 0C  E8 DF 60 FE - FF 8D 83 10  FF FF FF 8D ......`.........
[0073:08061B2D]---------------------------------------------------------[ code]
0x8061b2d <last_component+25>:  movzbl (%eax),%eax
0x8061b30 <last_component+28>:  cmp    $0x2f,%al
0x8061b32 <last_component+30>:  je     0x8061b26 <last_component+18>
0x8061b34 <last_component+32>:  mov    -0xc(%ebp),%eax
0x8061b37 <last_component+35>:  mov    %eax,-0x8(%ebp)
0x8061b3a <last_component+38>:  jmp    0x8061b60 <last_component+76>
------------------------------------------------------------------------------
0x08061b2d in last_component (name=0x0) at basename.c:38
38        while (ISSLASH (*base))
gdb> bt full
#0  0x08061b2d in last_component (name=0x0) at basename.c:38
        base = 0x0
        p = 0x8f6c030 " °\006\b"
        saw_slash = 0x0
#1  0x08061b80 in base_name (name=0x0) at basename.c:76
        base = 0x8f6c030 " °\006\b"
        length = 0x8f709e8
#2  0x080500b6 in F_find_alternate_file (uniarg=0x1, arglist=0x0) at file.c:425
        buf = 0x0
        base = 0x8f7ffc0 "p÷÷\b\004"
        ms = 0x8f711f8 "v\002"
        ok = (le *) 0x8f6c090
#3  0x0804c6cd in process_key (bindings=0x8f6d6f8, key=0x278) at bind.c:272
        keys = (gl_list_t) 0x8f6c030
        f = (Function) 0x805008d <F_find_alternate_file>
#4  0x080587d0 in loop () at main.c:70
        key = 0x278
#5  0x08059268 in main (argc=0x0, argv=0x7f818fb8) at main.c:407
        qflag = 0x0
        l_args = (gl_list_t) 0x8f6c008
        f_args = (gl_list_t) 0x8f6c030
        line = 0x1
        scratch_bp = (Buffer *) 0x8f7f540
gdb> up 2
#2  0x080500b6 in F_find_alternate_file (uniarg=0x1, arglist=0x0) at file.c:425
425       char *base = base_name (buf);
gdb> list
420     If the current buffer now contains an empty file that you just visited
421     (presumably by mistake), use this command to visit the file you really 
want.
422     +*/
423     {
424       const char *buf = get_buffer_filename (cur_bp);
425       char *base = base_name (buf);
426       char *ms = minibuf_read_filename ("Find alternate: ", buf, base);
427
428       ok = leNIL;
429
gdb> p buf
$1 = 0x0
gdb> 




reply via email to

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