aboutsummaryrefslogtreecommitdiff
path: root/src/sg_logs.c
diff options
context:
space:
mode:
authorDouglas Gilbert <dgilbert@interlog.com>2018-03-05 03:44:16 +0000
committerDouglas Gilbert <dgilbert@interlog.com>2018-03-05 03:44:16 +0000
commitbb1ca28ae1a69909b23522bcd412244b0c8e583c (patch)
tree5df479456e4f6b4d0a0dcc203abed41f69e03ff0 /src/sg_logs.c
parent090d6026610616895444792b75d90861b3c968f9 (diff)
downloadsg3_utils-bb1ca28ae1a69909b23522bcd412244b0c8e583c.tar.gz
sg_ses: --data=@FN with --status now decodes dpage(s) in FN; add --quiet option to suppress messages
git-svn-id: https://svn.bingwo.ca/repos/sg3_utils/trunk@758 6180dd3e-e324-4e3e-922d-17de1ae2f315
Diffstat (limited to 'src/sg_logs.c')
-rw-r--r--src/sg_logs.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/sg_logs.c b/src/sg_logs.c
index 034630d1..699cb41f 100644
--- a/src/sg_logs.c
+++ b/src/sg_logs.c
@@ -34,7 +34,7 @@
#include "sg_unaligned.h"
#include "sg_pr2serr.h"
-static const char * version_str = "1.61 20180218"; /* spc5r19 + sbc4r11 */
+static const char * version_str = "1.62 20180302"; /* spc5r19 + sbc4r11 */
#define MX_ALLOC_LEN (0xfffc)
#define SHORT_RESP_LEN 128
@@ -885,7 +885,7 @@ usage_for(int hval, const struct opts_t * op)
/* Processes command line options according to new option format. Returns
* 0 is ok, else SG_LIB_SYNTAX_ERROR is returned. */
static int
-process_cl_new(struct opts_t * op, int argc, char * argv[])
+new_parse_cmd_line(struct opts_t * op, int argc, char * argv[])
{
int c, n;
@@ -1063,7 +1063,7 @@ process_cl_new(struct opts_t * op, int argc, char * argv[])
/* Processes command line options according to old option format. Returns
* 0 is ok, else SG_LIB_SYNTAX_ERROR is returned. */
static int
-process_cl_old(struct opts_t * op, int argc, char * argv[])
+old_parse_cmd_line(struct opts_t * op, int argc, char * argv[])
{
bool jmp_out;
int k, plen, num, n;
@@ -1294,7 +1294,7 @@ process_cl_old(struct opts_t * op, int argc, char * argv[])
* of these options is detected (when processing the other format), processing
* stops and is restarted using the other format. Clear? */
static int
-process_cl(struct opts_t * op, int argc, char * argv[])
+parse_cmd_line(struct opts_t * op, int argc, char * argv[])
{
int res;
char * cp;
@@ -1302,14 +1302,14 @@ process_cl(struct opts_t * op, int argc, char * argv[])
cp = getenv("SG3_UTILS_OLD_OPTS");
if (cp) {
op->opt_new = false;
- res = process_cl_old(op, argc, argv);
+ res = old_parse_cmd_line(op, argc, argv);
if ((0 == res) && op->opt_new)
- res = process_cl_new(op, argc, argv);
+ res = new_parse_cmd_line(op, argc, argv);
} else {
op->opt_new = true;
- res = process_cl_new(op, argc, argv);
+ res = new_parse_cmd_line(op, argc, argv);
if ((0 == res) && (0 == op->opt_new))
- res = process_cl_old(op, argc, argv);
+ res = old_parse_cmd_line(op, argc, argv);
}
return res;
}
@@ -6698,7 +6698,7 @@ main(int argc, char * argv[])
op->dev_pdt = -1;
op->vend_prod_num = VP_NONE;
op->deduced_vpn = VP_NONE;
- res = process_cl(op, argc, argv);
+ res = parse_cmd_line(op, argc, argv);
if (res)
return SG_LIB_SYNTAX_ERROR;
if (op->do_help) {