~vcs-imports/qemu/git

« back to all changes in this revision

Viewing changes to tests/cris/check_sigalrm.c

  • Committer: blueswir1
  • Date: 2007-09-25 17:30:09 UTC
  • Revision ID: git-v1:eb296a0a03eebd2d73718d31cd0d8a8db0b804de
 Remove the target dependency introduced by previous patch


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@3239 c046a42c-6fe2-441c-8c8c-71466251a162

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#include <stdio.h>
2
 
#include <stdlib.h>
3
 
#include <signal.h>
4
 
#include <unistd.h>
5
 
 
6
 
#define MAGIC (0xdeadbeef)
7
 
 
8
 
int s = 0;
9
 
void sighandler(int sig)
10
 
{
11
 
        s = MAGIC;
12
 
}
13
 
 
14
 
int main(int argc, char **argv)
15
 
{
16
 
        int p;
17
 
 
18
 
        p = getpid();
19
 
        signal(SIGALRM, sighandler);
20
 
        kill(p, SIGALRM);
21
 
        if (s != MAGIC)
22
 
                return EXIT_FAILURE;
23
 
 
24
 
        printf ("passed\n");
25
 
        return EXIT_SUCCESS;
26
 
}