On 11/7/07, Michael Stepanov <[EMAIL PROTECTED]> wrote:
>
>
> On 11/7/07, Mika Yrjölä <[EMAIL PROTECTED]> wrote:
> > On 11/7/07, Michael Stepanov <[EMAIL PROTECTED]> wrote:
> > > Hi,
> > >
> > > I developed a simple Maemo application using its SDK which just run
> another
> > > SDL-based program with specified parameters. So, I'd like to catch the
> case
> > > when the SDL program crashed by some reason to run it again. What is the
> > > most efficient way to periodically check something in the Maemo SDK?
> >
> > If the launched program registers itself as a D-BUS service, other
> > applications can then monitor the service for events such as its
> > disappearance (also avoiding the need to check the status of the
> > application periodically).
>
> Sounds very attractive! But in what place I should call that check in the
> main program?

It's possible to setup the monitoring before or after launching the
other application. The following part of the D-BUS specification
describes a couple of useful methods and signals on the message bus,
which can be used for tracking the life of a service:

http://dbus.freedesktop.org/doc/dbus-specification.html#message-bus-types

The implementation details depend on whether you will use the
low-level libdbus or some higher level bindings, though, so I realize
this is still rather abstract description of how to do it :)
_______________________________________________
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers

Reply via email to