No Message Supplied
authorDean Roehrich <roehrich@sgi.com>
Thu, 6 Jun 2002 18:51:10 +0000 (18:51 +0000)
committerDean Roehrich <roehrich@sgi.com>
Thu, 6 Jun 2002 18:51:10 +0000 (18:51 +0000)
dmapi/src/common/cmd/set_region.c
dmapi/src/suite1/cmd/get_region.c

index 32f874ebf522e1d93d8202bb2b592d47e3754454..2bb884b9f7d491aa45a880cb32b318d25dbf46d0 100644 (file)
@@ -40,7 +40,7 @@
 Test program used to test the DMAPI function dm_set_region().  The
 command line is:
 
-       set_region [-n nelem] [-o offset] [-l length] [-s sid] pathname [event...]
+       set_region [-n nelem] [-o offset] [-l length] [-s sid] {pathname|handle} [event...]
 
 where pathname is the name of a file, nelem is the number of regions to pass
 in the call, offset is the offset of the start of
@@ -76,7 +76,7 @@ usage(void)
        int     i;
 
        fprintf(stderr, "usage:\t%s [-n nelem] [-o offset] [-l length] "
-               "[-s sid] pathname [event...]\n", Progname);
+               "[-s sid] {pathname|handle} [event...]\n", Progname);
        fprintf(stderr, "possible events are:\n");
        for (i = 0; i < nevents; i++)
                fprintf(stderr, "%s (0x%x)\n", rg_events[i].name, rg_events[i].value);
@@ -91,7 +91,7 @@ main(
 {
        dm_region_t     region = { 0, 0, 0 };
        dm_sessid_t     sid = DM_NO_SESSION;
-       char            *pathname = NULL;
+       char            *object = NULL;
        u_int           exactflag;
        u_int           nelem = 1;
        void            *hanp;
@@ -128,7 +128,7 @@ main(
        }
        if (optind + 1 > argc)
                usage();
-       pathname = argv[optind++];
+       object = argv[optind++];
 
        if (dm_init_service(&name) == -1)  {
                fprintf(stderr, "Can't initialize the DMAPI\n");
@@ -139,8 +139,8 @@ main(
 
        /* Get the file's handle. */
 
-       if (dm_path_to_handle(pathname, &hanp, &hlen)) {
-               fprintf(stderr, "can't get handle for file %s\n", pathname);
+       if (opaque_to_handle(object, &hanp, &hlen)) {
+               fprintf(stderr, "can't get handle for %s\n", object);
                exit(1);
        }
 
index 79629f5ea4df80ae9101d0f6820247f982cd3e8b..767e146ecd889729ffa1ac6a47c466d2c220eee7 100644 (file)
@@ -40,7 +40,7 @@
 Test program used to test the DMAPI function dm_set_region().  The
 command line is:
 
-       get_region [-n nelem] [-s sid] pathname
+       get_region [-n nelem] [-s sid] {pathname|handle}
 
 where pathname is the name of a file, nelem is the number of regions to pass
 in the call, and sid is the session ID whose events you you are interested in.
@@ -60,7 +60,7 @@ char  *Progname;
 static void
 usage(void)
 {
-       fprintf(stderr, "usage:\t%s [-n nelem] [-s sid] pathname\n", Progname);
+       fprintf(stderr, "usage:\t%s [-n nelem] [-s sid] {pathname|handle}\n", Progname);
        exit(1);
 }
 
@@ -72,7 +72,7 @@ main(
 {
        dm_sessid_t     sid = DM_NO_SESSION;
        dm_region_t     *regbufp = NULL;
-       char            *pathname = NULL;
+       char            *object = NULL;
        u_int           nelemp;
        u_int           nelem = 1;
        void            *hanp;
@@ -103,7 +103,7 @@ main(
        }
        if (optind + 1 != argc)
                usage();
-       pathname = argv[optind++];
+       object = argv[optind++];
 
        if (dm_init_service(&name) == -1)  {
                fprintf(stderr, "Can't initialize the DMAPI\n");
@@ -114,8 +114,8 @@ main(
 
        /* Get the file's handle. */
 
-       if (dm_path_to_handle(pathname, &hanp, &hlen)) {
-               fprintf(stderr, "can't get handle for file %s\n", pathname);
+       if (opaque_to_handle(object, &hanp, &hlen)) {
+               fprintf(stderr, "can't get handle for %s\n", object);
                exit(1);
        }