package checkinstall
tag 702314 patch pending
thanks

Hi,

I can reproduce this on amd64 and i386. The following is from
fisher.debian.org (i386):

/bin/dash -c 
'LD_PRELOAD=/home/lindi/debian/debian-checkinstall/checkinstall-1.6.2/installwatch/installwatch.so
 exec cat /etc/motd'
Illegal instruction

Debugger shows that the crash happens at 0x2807ac72 which is mapped to
the installwatch.so according to /proc.

Program received signal SIGILL, Illegal instruction.
0x2807ac72 in ?? () from /lib/ld.so.1
(gdb) x/4i $eip-6
   0x2807ac6c:  lea    0x10(%ebp),%eax
   0x2807ac6f:  mov    %eax,-0xc(%ebp)
=> 0x2807ac72:  ud2    
   0x2807ac74:  push   %ebp

This is the last instruction of the open function. objdump of the .so
confirms that the function indeed contains some "ud2a" instruction:

00006c11 <open>:
    6c11:       55                      push   %ebp
    6c12:       89 e5                   mov    %esp,%ebp
    6c14:       53                      push   %ebx
    6c15:       81 ec 64 18 00 00       sub    $0x1864,%esp
    6c1b:       e8 d9 34 00 00          call   a0f9 <__x86.get_pc_thunk.bx>
    6c20:       81 c3 b4 54 00 00       add    $0x54b4,%ebx
    6c26:       8b 83 f4 ff ff ff       mov    -0xc(%ebx),%eax
    6c2c:       8b 00                   mov    (%eax),%eax
    6c2e:       8d 50 01                lea    0x1(%eax),%edx
    6c31:       8b 83 f4 ff ff ff       mov    -0xc(%ebx),%eax
    6c37:       89 10                   mov    %edx,(%eax)
    6c39:       8b 83 08 1a 00 00       mov    0x1a08(%ebx),%eax
    6c3f:       85 c0                   test   %eax,%eax
    6c41:       75 05                   jne    6c48 <open+0x37>
    6c43:       e8 66 a6 ff ff          call   12ae <initialize>
    6c48:       8b 45 0c                mov    0xc(%ebp),%eax
    6c4b:       89 44 24 0c             mov    %eax,0xc(%esp)
    6c4f:       8b 45 08                mov    0x8(%ebp),%eax
    6c52:       89 44 24 08             mov    %eax,0x8(%esp)
    6c56:       8d 83 47 ec ff ff       lea    -0x13b9(%ebx),%eax
    6c5c:       89 44 24 04             mov    %eax,0x4(%esp)
    6c60:       c7 04 24 02 00 00 00    movl   $0x2,(%esp)
    6c67:       e8 15 af ff ff          call   1b81 <debug>
    6c6c:       8d 45 10                lea    0x10(%ebp),%eax
    6c6f:       89 45 f4                mov    %eax,-0xc(%ebp)
    6c72:       0f 0b                   ud2a   

Now, the build log talks about this:

gcc -Wall -c -D_GNU_SOURCE -DPIC -fPIC -D_REENTRANT -DVERSION=\"0.7.0beta7\" 
installwatch.c
installwatch.c: In function '__instw_printdirent64':
installwatch.c:1037:4: warning: format '%lld' expects argument of type 'long 
long int', but argument 4 has type 'unsigned int' [-Wformat]
installwatch.c:1037:4: warning: format '%lld' expects argument of type 'long 
long int', but argument 5 has type 'int' [-Wformat]
installwatch.c: In function 'openat':
installwatch.c:3835:11: warning: 'short unsigned int' is promoted to 'int' when 
passed through '...' [enabled by default]
installwatch.c:3835:11: note: (so you should pass 'int' not 'short unsigned 
int' to 'va_arg')
installwatch.c:3835:11: note: if this code is reached, the program will abort
installwatch.c: In function 'open64':
installwatch.c:3598:9: warning: 'short unsigned int' is promoted to 'int' when 
passed through '...' [enabled by default]
installwatch.c:3598:9: note: if this code is reached, the program will abort
installwatch.c: In function 'open':
installwatch.c:2821:9: warning: 'short unsigned int' is promoted to 'int' when 
passed through '...' [enabled by default]
installwatch.c:2821:9: note: if this code is reached, the program will abort
installwatch.c: In function 'fopen':
installwatch.c:2539:7: warning: 'result' may be used uninitialized in this 
function [-Wuninitialized]
installwatch.c:2509:8: note: 'result' was declared here
ld -shared -o installwatch.so installwatch.o -ldl -lc

I tried to register to upstream bug tracker but while writing this I
still haven't received the confirmation email. I pushed patches to
http://git.debian.org/?p=collab-maint/checkinstall.git;a=summary and
built with pbuilder to see that there are no obvious regressions on
amd64 (linux).


-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to