Bug#512839: Thanks

2009-01-31 Thread garkein
Thanks Ben, I can now watch TV again. :)

Regarding xdg-utils: I have version 1.0.2-6.1 installed and the
xdg-screensaver processed still cumulate (don't terminate).
No idea why.

Regards,
Daniel





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



Bug#512839: Your 'xine-ui' NMU introduced new RC bug #512839

2009-01-30 Thread Ben Hutchings
On Fri, 2009-01-30 at 12:28 +0200, Jonathan Quick wrote:
 (re-sending with subject)
 
 Hi Ben
 
 I assume you're aware of the RC bug #512839 introduced by your NMU (and in
 testing) xine-ui/0.99.5+cvs20070914-2.1 ?

No, I missed that.  The bug is clearly not grave; not sure whether it
should be RC.

 Looks like the fork()ing of xdg-screensaver needs a little more thought.

I'm afraid I was a bit lazy about this.  The previous code which forked
gnome-screensaver-command did not close fds either, so I assumed that
would be fine, but since xdg-screensaver's child processes hang around
it's not.

The correct thing to do is to close all fds above 2 before calling
execve() in the child process.

Ben.



signature.asc
Description: This is a digitally signed message part


Bug#512839: Depends on what you use xine for

2009-01-30 Thread garkein
Ben,
I understand that you don't agree with the bug being grave. The point is
that I use it mainly for watching TV.
This is practically not possible anymore now since the VDR playback
breaks on every channel switch due to xdg-screensaver hogging the audio
handle. For that usage it is definately a grave bug because it rendered
my main application useless.
I know this may not affect all users, but I also find it a bit harsh to
say a bug is clearly not grave just because one is mainly using a xine
plugin that has been effectively broken now.

Just as a remark regarding your intended fix: I haven't yet seen the
place where xine does a wait() or waitpid() for those forked childs to
clean up the zombies. If there is a place, ok, I just havn't seen it
yet.

If I startup the XVDR plugin, I see three pid's of xdg-screensaver. Upon
each TV channel switch, there's one more. They also don't seem to
terminate, so the list is growing. Aren't they supposed to just signal a
suspend and then terminate themselves?

Regards,
Daniel




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



Bug#512839: Your 'xine-ui' NMU introduced new RC bug #512839

2009-01-30 Thread Ben Hutchings
gark...@mailueberfall.de wrote
 I understand that you don't agree with the bug being grave. The point is
 that I use it mainly for watching TV.
 This is practically not possible anymore now since the VDR playback
 breaks on every channel switch due to xdg-screensaver hogging the audio
 handle. For that usage it is definately a grave bug because it rendered
 my main application useless.
 I know this may not affect all users, but I also find it a bit harsh to
 say a bug is clearly not grave just because one is mainly using a xine
 plugin that has been effectively broken now.

I sympathise, but the definition is:

grave
makes the package in question unusable or mostly so, or causes
data loss, or introduces a security hole allowing access to the
accounts of users who use the package.

I think that this bug is:

important
a bug which has a major effect on the usability of a package,
without rendering it completely unusable to everyone.

but it's up to the maintainer to decide.

 Just as a remark regarding your intended fix: I haven't yet seen the
 place where xine does a wait() or waitpid() for those forked childs to
 clean up the zombies. If there is a place, ok, I just havn't seen it
 yet.

I added signal(SIGCHLD, SIG_IGN) which should make that unnecessary.

Also, the change I actually made to xine-ui *does* include a loop to
close fds 3-255 (sadly there is no easy way to find out what the last
open fd is).  So unless xine is opening a *huge* number of files I can't
understand this bug.

Please could you run ls -l /proc/$pid/fd/ for the pid of the
xdg-screensaver process when this bug is triggered?

 If I startup the XVDR plugin, I see three pid's of xdg-screensaver. Upon
 each TV channel switch, there's one more. They also don't seem to
 terminate, so the list is growing. Aren't they supposed to just signal a
 suspend and then terminate themselves?

Which version of xdg-utils do you have installed?  There was a bug in
that which could result in zombie processes, but I fixed that before
making this change.

Ben.



signature.asc
Description: This is a digitally signed message part


Bug#512839: Your 'xine-ui' NMU introduced new RC bug #512839

2009-01-30 Thread Ben Hutchings
On Sat, 2009-01-31 at 02:25 +, Ben Hutchings wrote:
  Just as a remark regarding your intended fix: I haven't yet seen the
  place where xine does a wait() or waitpid() for those forked childs to
  clean up the zombies. If there is a place, ok, I just havn't seen it
  yet.
 
 I added signal(SIGCHLD, SIG_IGN) which should make that unnecessary.
 
 Also, the change I actually made to xine-ui *does* include a loop to
 close fds 3-255 (sadly there is no easy way to find out what the last
 open fd is).  So unless xine is opening a *huge* number of files I can't
 understand this bug.

OK, now I see what's happened.  The correct fix for #374644 is in sid,
but not in lenny.  Because the new version of xine-ui in sid changed
library dependencies, it could not propagate to lenny and I had to
upload separately to testing-proposed-updates.  I mistakenly uploaded an
earlier version of the changes which has this bug.  I will upload a new
version to t-p-u.

Ben.



signature.asc
Description: This is a digitally signed message part


Bug#512839:

2009-01-29 Thread Jonathan Quick
Hi Ben

I assume you're aware of the RC bug #512839 introduced by your NMU (and in
testing) xine-ui/0.99.5+cvs20070914-2.1 ?  Looks like the fork()ing of
xdg-screensaver needs a little more thought.

Regards
  Jon




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



Bug#512839: xine-ui: xdg-screensaver broke XVDR plugin

2009-01-24 Thread Daniel
Package: xine-ui
Version: 0.99.5+cvs20070914-2.1~lenny1
Severity: grave
Justification: renders package unusable


The last patch of xine-ui
Change screensaver control code to use xdg-screensaver instead of
faking keystrokes
seems to have broken VDR playback via XVDR plugin. On channel change,
playback stops with

audio_alsa_out: snd_pcm_open() von default schlug fehl: Das Gerät oder die 
Resso
urce ist belegt
audio_alsa_out:  Überprüfen Sie, ob ein anderen Programm PCM bereits benutzt

audio_out: open failed!

which means that audio cannot be re-opened.
If I now grep through /proc/*/fd to see which program may (still) sit on
an audio file handle, it turns out to be xdg-screensaver.

thinkpad:/home/dd# ls -l /proc/*/fd |grep pcm
lrwx-- 1 dd dd 64 24. Jan 12:14 10 - /dev/snd/pcmC0D0p
lrwx-- 1 dd dd 64 24. Jan 12:14 10 - /dev/snd/pcmC0D0p
thinkpad:/home/dd# ls -l /proc/*/fd |less (searched here for pcm in less)
thinkpad:/home/dd# ps ax | grep 11900
11900 ?S  0:00 /bin/sh /usr/bin/xdg-screensaver suspend 69206991
12025 pts/1R+ 0:00 grep 11900

It looks very much as if someone had forked xine to then exec xdg-screensaver
without closing all file handles before which leads to xdg-screensaver 
sitting on the audio file handles.


-- System Information:
Debian Release: 5.0
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.28 (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages xine-ui depends on:
ii  libc6 2.7-18 GNU C Library: Shared libraries
ii  libcurl3-gnutls   7.18.2-8   Multi-protocol file transfer libra
ii  libpng12-01.2.27-2   PNG library - runtime
ii  libreadline5  5.2-3  GNU readline and history libraries
ii  libx11-6  2:1.1.5-2  X11 client-side library
ii  libxext6  2:1.0.4-1  X11 miscellaneous extension librar
ii  libxft2   2.1.12-3   FreeType-based font drawing librar
ii  libxine1  1.1.14-5   the xine video/media player librar
ii  libxine1-ffmpeg   1.1.14-5   MPEG-related plugins for libxine1
ii  libxine1-x1.1.14-5   X desktop video output plugins for
ii  libxinerama1  2:1.0.3-2  X11 Xinerama extension library
ii  libxtst6  2:1.0.3-1  X11 Testing -- Resource extension 
ii  libxv12:1.0.4-1  X11 Video extension library
ii  libxxf86vm1   1:1.0.2-1  X11 XFree86 video mode extension l

Versions of packages xine-ui recommends:
ii  xdg-utils 1.0.2-6.1  desktop integration utilities from

xine-ui suggests no packages.

-- no debconf information



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



Bug#512839: Further details

2009-01-24 Thread garkein
Oh,
and I want to add that waiting for the child processes also seems to be
missing. At least that's what the amount of zombies seems to suggest:

thinkpad:/home/dd# ps ax |grep xdg-screensaver
11592 ?Z  0:00 [xdg-screensaver] defunct
11631 ?Z  0:00 [xdg-screensaver] defunct
11660 ?Z  0:00 [xdg-screensaver] defunct
11702 ?Z  0:00 [xdg-screensaver] defunct
11731 ?Z  0:00 [xdg-screensaver] defunct
11773 ?Z  0:00 [xdg-screensaver] defunct
11813 ?Z  0:00 [xdg-screensaver] defunct
11852 ?Z  0:00 [xdg-screensaver] defunct
11881 ?Z  0:00 [xdg-screensaver] defunct
11925 ?Z  0:00 [xdg-screensaver] defunct
11955 ?Z  0:00 [xdg-screensaver] defunct
11974 ?S  0:00 /bin/sh /usr/bin/xdg-screensaver suspend
69206991
11991 ?Z  0:00 [xdg-screensaver] defunct
12193 ?Z  0:00 [xdg-screensaver] defunct
12232 ?Z  0:00 [xdg-screensaver] defunct
12262 ?Z  0:00 [xdg-screensaver] defunct
12281 ?S  0:00 /bin/sh /usr/bin/xdg-screensaver suspend
69206991
12296 ?Z  0:00 [xdg-screensaver] defunct


If I look at #374644, I find

+if(fork() == 0) {
+  execvp(args[0], args);
+  _exit(0);
 }

which confirms my assumption of unproper forking.

If I manually kill all xdg-screensaver instances, I can successfully
reopen the XVDR plugin.
If I change the TV channel, playback again breaks, again with
xdg-screensaver instances running and blocking the audio file handles
(three of them actually.)

I hope this is sufficient information to fix this bug.

Regards,
Daniel





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