Bug 31739 - Не выполняется exec корректно
Summary: Не выполняется exec корректно
Status: CLOSED NOTABUG
Alias: None
Product: Sisyphus
Classification: Development
Component: tk (show other bugs)
Version: unstable
Hardware: all Linux
: P3 normal
Assignee: Vladimir D. Seleznev
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-28 21:01 MSK by Vitaly Lipatov
Modified: 2016-01-28 22:35 MSK (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vitaly Lipatov 2016-01-28 21:01:16 MSK
Предположительно после обновления до git-gui-2.6.5-alt2 перестал запускаться git gui.

Сообщение:
Cannot determine Git version:

error waiting for process to exit: child process lost (is SIGCHLD ignored or trapped?)

Git Gui requires Git 1.5.0 or later.

Код проверки:
if {[catch {set _git_version [git --version]} err]} {
<------>catch {wm withdraw .}
<------>tk_messageBox \
<------><------>-icon error \
<------><------>-type ok \
<------><------>-title [mc "git-gui: fatal error"] \
<------><------>-message "Cannot determine Git version:

$err

[appname] requires Git 1.5.0 or later."
<------>exit 1
}


На другой машине, равно обновлённой до Сизифа, всё работает.
Comment 1 Vitaly Lipatov 2016-01-28 22:09:03 MSK
Тестовый скрипт:
#!/usr/bin/wish

set _git  {/usr/bin/git}

proc _git_cmd {name} {
        return [list $::_git $name]
}

proc git {args} {
        set opt [list]

        set cmdp [_git_cmd [lindex $args 0]]
        set args [lrange $args 1 end]

        set result [eval exec $opt $cmdp $args]
        puts stderr "< $result"
        return $result
}

git --version

strace:

pid 13416] pipe([6<pipe:[143743268]>, 7<pipe:[143743268]>]) = 0
[pid 13416] fcntl(6<pipe:[143743268]>, F_SETFD, FD_CLOEXEC) = 0
[pid 13416] fcntl(7<pipe:[143743268]>, F_SETFD, FD_CLOEXEC) = 0
[pid 13416] open("/tmp/tcliCOyqF", O_RDWR|O_CREAT|O_EXCL, 0600) = 9</tmp/tcliCOyqF>
[pid 13416] fcntl(9</tmp/tcliCOyqF>, F_SETFD, FD_CLOEXEC) = 0
[pid 13416] unlink("/tmp/tcliCOyqF")    = 0
[pid 13416] pipe([10<pipe:[143743271]>, 11<pipe:[143743271]>]) = 0
[pid 13416] fcntl(10<pipe:[143743271]>, F_SETFD, FD_CLOEXEC) = 0
[pid 13416] fcntl(11<pipe:[143743271]>, F_SETFD, FD_CLOEXEC) = 0
[pid 13416] close(11<pipe:[143743271]>) = 0
[pid 13416] read(10<pipe:[143743271]>, "", 223) = 0
[pid 13416] close(10<pipe:[143743271]>) = 0
[pid 13416] close(7<pipe:[143743268]>)  = 0
[pid 13416] read(6<pipe:[143743268]>, "", 4096) = 0
[pid 13416] close(6<pipe:[143743268]>)  = 0
[pid 13416] ioctl(9< (deleted)/tmp/tcliCOyqF>, TCGETS, 0x7ffe29879b50) = -1 ENOTTY (Inappropriate ioctl for device)
[pid 13416] getsockname(9< (deleted)/tmp/tcliCOyqF>, 0x7ffe29879bf0, 0x7ffe29879bec) = -1 ENOTSOCK (Socket operation on non-socket)
[pid 13416] wait4(1298893056, 0x7ffe29879bd0, 0, NULL) = -1 ECHILD (No child processes)
[pid 13416] lseek(9< (deleted)/tmp/tcliCOyqF>, 0, SEEK_SET) = 0
[pid 13416] read(9< (deleted)/tmp/tcliCOyqF>, "", 4096) = 0
[pid 13416] close(9< (deleted)/tmp/tcliCOyqF>) = 0
[pid 13416] write(2</dev/pts/13>, "Error in startup script", 23Error in startup script) = 23
Comment 2 Vitaly Lipatov 2016-01-28 22:22:48 MSK
Судя по скрипту, проблема адресуется к wish из tk.
Проверялось на tk-8.5.9-alt3
Comment 3 Vitaly Lipatov 2016-01-28 22:24:49 MSK
Было
# rpm -V tk
S.......   /usr/bin/wish8.5

то есть проблемы с размером файла.

После переустановки пакета tk всё заработало.
Comment 4 Vitaly Lipatov 2016-01-28 22:35:37 MSK
Проблему вызывает запуск
# prelink /usr/bin/wish8.5