~ubuntu-branches/ubuntu/quantal/jackd2/quantal

« back to all changes in this revision

Viewing changes to example-clients/ipload.c

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler, Adrian Knoth, Reinhard Tartler, Jonas Smedegaard
  • Date: 2010-06-19 18:54:29 UTC
  • Revision ID: james.westby@ubuntu.com-20100619185429-zhbhh0mqvukgzx0l
Tags: 1.9.5~dfsg-15
[ Adrian Knoth ]
* Also provide the shlibs file for libjack-jackd2-0
* Fix FTBFS on sparc64 (Closes: #586257)

[ Reinhard Tartler ]
* jackd must not be a virtual package, use 'jack-daemon' for that
* add breaks/replaces on old libjack0
* change shlibsfile to prefer jackd2's libjack
* use conflicts instead of breaks. libjack-jackd2-0 has file conflicts
  with libjack0 and will keep it

[ Jonas Smedegaard ]
* Update control file.

Show diffs side-by-side

added added

removed removed

Lines of Context:
17
17
#include <stdio.h>
18
18
#include <stdlib.h>
19
19
#include <string.h>
20
 
#include <signal.h>
 
20
#include <signal.h>
21
21
#ifndef WIN32
22
 
#include <unistd.h>
 
22
#include <unistd.h>
23
23
#endif
24
24
#include <getopt.h>
25
25
#include <jack/jack.h>
126
126
int
127
127
main (int argc, char *argv[])
128
128
{
129
 
        jack_status_t status;
 
129
        jack_status_t status;
130
130
        char* name;
131
131
 
132
132
        /* parse and validate command arguments */
157
157
                                               (JackLoadName|JackLoadInit),
158
158
                                               &status, load_name, load_init);
159
159
        if (status & JackFailure) {
160
 
                fprintf (stderr, "could not load %s, status = 0x%2.0x\n",
161
 
                         load_name, status);
 
160
                fprintf (stderr, "could not load %s, intclient = %d status = 0x%2.0x\n",
 
161
                         load_name, (int)intclient, status);
162
162
                return 2;
163
163
        }
164
164
        if (status & JackNameNotUnique) {
178
178
 
179
179
        if (wait_opt) {
180
180
                /* define a signal handler to unload the client, then
181
 
                 * wait for it to exit */
182
 
        #ifdef WIN32
183
 
                signal(SIGINT, signal_handler);
184
 
                signal(SIGABRT, signal_handler);
185
 
                signal(SIGTERM, signal_handler);
186
 
        #else
187
 
                signal(SIGQUIT, signal_handler);
188
 
                signal(SIGTERM, signal_handler);
189
 
                signal(SIGHUP, signal_handler);
190
 
                signal(SIGINT, signal_handler);
191
 
        #endif
 
181
                 * wait for it to exit */
 
182
        #ifdef WIN32
 
183
                signal(SIGINT, signal_handler);
 
184
                signal(SIGABRT, signal_handler);
 
185
                signal(SIGTERM, signal_handler);
 
186
        #else
 
187
                signal(SIGQUIT, signal_handler);
 
188
                signal(SIGTERM, signal_handler);
 
189
                signal(SIGHUP, signal_handler);
 
190
                signal(SIGINT, signal_handler);
 
191
        #endif
192
192
 
193
 
                while (1) {
194
 
                        #ifdef WIN32
195
 
                                Sleep(1000);
 
193
                while (1) {
 
194
                        #ifdef WIN32
 
195
                                Sleep(1000);
196
196
                        #else
197
 
                                sleep (1);
 
197
                                sleep (1);
198
198
                        #endif
199
199
                }
200
200
        }