return -1;
}
-int net_help_status(struct net_context *c, int argc, const char **argv)
-{
- d_printf(" net status sessions [parseable] "
- "Show list of open sessions\n");
- d_printf(" net status shares [parseable] "
- "Show list of open shares\n");
- return -1;
-}
-
static int net_usage(struct net_context *c, int argc, const char **argv)
{
d_printf(" net time\t\tto view or set time information\n"\
/* The following definitions come from utils/net_help.c */
-int net_help_status(struct net_context *c, int argc, const char **argv);
int net_help(struct net_context *c, int argc, const char **argv);
/* The following definitions come from utils/net_idmap.c */
/* The following definitions come from utils/net_status.c */
+int net_status_usage(struct net_context *c, int argc, const char **argv);
int net_status(struct net_context *c, int argc, const char **argv);
/* The following definitions come from utils/net_time.c */
#include "includes.h"
#include "utils/net.h"
+int net_status_usage(struct net_context *c, int argc, const char **argv)
+{
+ d_printf(" net status sessions [parseable] "
+ "Show list of open sessions\n");
+ d_printf(" net status shares [parseable] "
+ "Show list of open shares\n");
+ return -1;
+}
+
static int show_session(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
void *state)
{
} else if ((argc == 1) && strequal(argv[0], "parseable")) {
parseable = true;
} else {
- return net_help_status(c, argc, argv);
+ return net_status_usage(c, argc, argv);
}
if (!parseable) {
}
if ((argc != 1) || !strequal(argv[0], "parseable")) {
- return net_help_status(c, argc, argv);
+ return net_status_usage(c, argc, argv);
}
return net_status_shares_parseable(c, argc, argv);
struct functable func[] = {
{"sessions", net_status_sessions},
{"shares", net_status_shares},
+ {"help", net_status_usage},
{NULL, NULL}
};
- return net_run_function(c, argc, argv, func, net_help_status);
+ return net_run_function(c, argc, argv, func, net_status_usage);
}