From d889623dae96e7f4138b5c6946a1c53468025aed Mon Sep 17 00:00:00 2001 From: Enrico Scholz Date: Thu, 29 Jan 2004 11:04:44 +0000 Subject: [PATCH] use DIM_OF() macro added APIVER tag fixed help message git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@726 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- util-vserver/src/vserver-info.c | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/util-vserver/src/vserver-info.c b/util-vserver/src/vserver-info.c index 16eba18..10ea63b 100644 --- a/util-vserver/src/vserver-info.c +++ b/util-vserver/src/vserver-info.c @@ -33,6 +33,7 @@ typedef enum { tgNONE,tgCONTEXT, tgRUNNING, tgVDIR, tgNAME, tgCFGDIR, tgAPPDIR, + tgAPIVER, tgINITPID, tgINITPID_PID, tgXID, } VserverTag; @@ -51,10 +52,9 @@ static struct { { "INITPID", tgINITPID, "gives out the initpid of the given context" }, { "INITPID_PID", tgINITPID_PID, "gives out the initpid of the given pid" }, { "XID", tgXID, "gives out the context-id of the given pid" }, + { "APIVER", tgAPIVER, "gives out the version of the kernel API" } }; -#define TAGS_COUNT (sizeof(TAGS)/sizeof(TAGS[0])) - int wrapper_exit_code = 1; static struct option const @@ -71,7 +71,7 @@ showHelp(int fd, char const *cmd, int res) WRITE_MSG(fd, "Usage: "); WRITE_STR(fd, cmd); WRITE_MSG(fd, - " [-q] || \n" + " [-ql] || \n" "Please report bugs to " PACKAGE_BUGREPORT "\n"); exit(res); } @@ -94,7 +94,7 @@ showTags() size_t i; WRITE_MSG(1, "Valid tags are: "); - for (i=0; i