|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2002-06-16 10:26 UTC] msopacua at idg dot nl
/chroot/home/mdev/php4-200206160300/ext/sysvsem/sysvsem.c: In function `zif_sem_remove': /chroot/home/mdev/php4-200206160300/ext/sysvsem/sysvsem.c:382: incompatible type for argument 4 of `semctl' /chroot/home/mdev/php4-200206160300/ext/sysvsem/sysvsem.c:391: incompatible type for argument 4 of `semctl' The fix seems to be to replace &un by un in the corresponding lines. PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 01:00:02 2025 UTC |
Thanx Derick :-) The problem seems to be more than a compiling issue only. On FreeBSD (tested on 4.5 and 4.6) this compiles ok, but than segfaults on it. The problem is however with the sysvsem_sem struct: Program received signal SIGSEGV, Segmentation fault. 0x813bdef in zif_sem_remove (ht=0, return_value=0x3d3c4f16, this_ptr=0x0, return_value_used=0) at /home/mdev/cvs/php4/ext/sysvsem/sysvsem.c:391 391 if(semctl(sem_ptr->semid, 0, IPC_RMID, &un) < 0) { (gdb) bt #0 0x813bdef in zif_sem_remove (ht=0, return_value=0x3d3c4f16, this_ptr=0x0, return_value_used=0) at /home/mdev/cvs/php4/ext/sysvsem/sysvsem.c:391 #1 0x0 in ?? () (gdb) print un $1 = {val = 656363, buf = 0xa03eb, array = 0xa03eb} (gdb) print &un $2 = (union semun *) 0xbfbfbdbc (gdb) print sem_ptr $3 = (sysvsem_sem *) 0xa03eb (gdb) print sem_ptr->semid Error accessing memory address 0xa03f3: Bad address. I noticed that the union for FreeBSD is also different, than the one declared in sysvsem.c - especially the seminfo *__buf pointer is missing. So this may require some more attention, than just a compile fix.