source: trunk/packages/xen-3.1/xen-3.1/tools/xenstore/xenstore_control.c @ 34

Last change on this file since 34 was 34, checked in by hartmans, 18 years ago

Add xen and xen-common

File size: 537 bytes
Line 
1#include <stdio.h>
2#include <stdlib.h>
3#include <string.h>
4
5#include "xs.h"
6
7
8int main(int argc, char **argv)
9{
10  struct xs_handle * xsh;
11
12  if (argc < 2 ||
13      strcmp(argv[1], "check"))
14  {
15    fprintf(stderr,
16            "Usage:\n"
17            "\n"
18            "       %s check\n"
19            "\n", argv[0]);
20    return 2;
21  }
22
23  xsh = xs_daemon_open();
24
25  if (xsh == NULL) {
26    fprintf(stderr, "Failed to contact Xenstored.\n");
27    return 1;
28  }
29
30  xs_debug_command(xsh, argv[1], NULL, 0);
31
32  xs_daemon_close(xsh);
33
34  return 0;
35}
Note: See TracBrowser for help on using the repository browser.