On Tue, 16 Nov 1999, Caolan McNamara wrote:
> On 16-Nov-99 Mel wrote:
> >
> >Pipe wouldnt' work in this case because the child is executed with
> >system(). If I didn't use system, I would be using execl because I need a
> >totally seperate process, a copy with fork doesn't work. Can I use a pipe
> >with that sort of setup? I think atexit() (new function to me) might do
> >the job but at the moment, it's causing segfaults. I have a feeling it's
> >because the quit function is part of a library which is loaded at runtime.
> >By program termination, the library has been unloaded with my quit
> >function along with it (no, I can't compile the quit function into the
> >main part of the program). What does work, is trapping SIGUSR1 in the
> >parent and periodically getting the child to send SIGUSR1. If it fails, it
> >dies. God, the architecture for this program is beginning to irritate me.
>> Plop the source somewhere, comment what you want to do in the source and
> give us some pointers to it and someone might have a look at it and fix it.
> Show us the source baby.
>
ouch! I'm almost embarassed to show it as it stood so I did bitty piece of
work and made it stand on it's own rather than patching xmms. The code is
a plugin for XMMS to play vqf's (it's looking a bit prettier now Kevin :-)
). It's at
http://www.csn.ul.ie/~mel/projects/linux/vqfplugin/vqfplugin-0.3.tar.gz
For what it's worth, it *works*. Not pretty, not good code, but working
code. I'd appreciate pointers on how to make it better code wise in terms
of style and approach. IE recommend a better IPC mechanism than shared
memory, figure a good way of killing vqfhandle (the child). It's tied
fairly heavily to XMMS and I'm bound a lot of XMMS's architecture hence my
problems. For anyone who looks at it, I'm willing to explain what I know
about XMMS code itself (an entertaining read of code :-) ).
Also, I know visualisations and seeking don't work. That involves
overriding WINE audio functions which I haven't got around to yet - final
year being what it is.
I'll be putting this up on my website later this evening and it's also
going to be my entry into the XMMS plugin competition so recommended code
improvements are very welcomeas long as they aren't awkward :-)
Mel
Maintained by the ILUG website team. The aim of Linux.ie is to
support and help commercial and private users of Linux in Ireland. You can
display ILUG news in your own webpages, read backend
information to find out how. Networking services kindly provided by HEAnet, server kindly donated by
Dell. Linux is a trademark of Linus Torvalds,
used with permission. No penguins were harmed in the production or maintenance
of this highly praised website. Looking for the
Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!