[<<] [<] Page 1 of 1 [>] [>>] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Best way to restart/shutdown app
From: Alex Pavloff ####@####.#### Date: 26 Apr 2002 17:14:52 -0000 Message-Id: <D3AF5F134D627243993F2F2FC32EE4D20CDFBA@mailman.eason.com> Hello folks. Question: I have a background process monitoring a serial port and a TCP port. Based off of information from that process, I want to start/stop a Nano-X application. Sequence of events goes something like this: 1) Main Application is running. 2) User on the other end of the serial port or TCP starts a download 3) Main Application is stopped 4) Standby Application is run (with some config settings) 5) New files are downloaded 6) Main application is re-launched. Whats the best way to to do? Keep the Nano-X server running and just start and stop the application? Alex Pavloff Software Engineer Eason Technology | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Best way to restart/shutdown app
From: Alex Holden ####@####.#### Date: 26 Apr 2002 18:29:57 -0000 Message-Id: <3CC99AB0.5050006@linuxhacker.org> Alex Pavloff wrote: > 1) Main Application is running. > 2) User on the other end of the serial port or TCP starts a download > 3) Main Application is stopped The simplest way might be to just do: system("killall your_app"); Or store the PID in a file somewhere when it is started and use that to supply the argument to kill(). You could use SIGUSR1 and have the main app catch that signal if you want it to do some special processing as it shuts down that wouldn't normally be done if the program was killed. -- ------------ Alex Holden - http://www.linuxhacker.org ------------ If it doesn't work, you're not hitting it with a big enough hammer | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Subject:
Re: [nanogui] Best way to restart/shutdown app
From: "Greg Haerr" ####@####.#### Date: 29 Apr 2002 16:34:11 -0000 Message-Id: <01b701c1ef9a$58c5e1d0$6401a8c0@gregnewport> > Whats the best way to to do? Keep the Nano-X server running and just start > and stop the application? If you don't mind keeping screen in graphics mode, keeping the nano-X server running will allow other programs to access the screen graphically. Starting/stopping client applications doesn't affect the screen, except that stopping an application will cause all client windows to be destroyed. Regards, Greg | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
[<<] [<] Page 1 of 1 [>] [>>] |