summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYi Sun <yi.sun@intel.com>2015-03-12 15:18:21 +0800
committerYi Sun <yi.sun@intel.com>2015-03-12 15:18:21 +0800
commit0f23d3ae6450c819de8f9b05fb271a43f11c1233 (patch)
treeb35ccc124667522e0499a8e3601fc6585b8d59d1
parent89d5c776554a19a559e8c2c43d8d293a7ab996cc (diff)
Refine options related.
Signed-off-by: Yi Sun <yi.sun@intel.com>
-rw-r--r--tools/vtview.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/tools/vtview.c b/tools/vtview.c
index 6d01f6d..929b0ea 100644
--- a/tools/vtview.c
+++ b/tools/vtview.c
@@ -442,19 +442,21 @@ int main(int argc, char **argv)
isl.img_w = atoi(strtok(NULL,delims));
isl.img_x = atoi(strtok(NULL,delims));
break;
+
case 'n':
- case ':':
+ default:
+ printf("Image name: %s \n", optarg);
image_name = optarg;
break;
+ case ':':
+ printf("Need a augument %c\n", c);
+ break;
case '?':
- printf("i'm here2!!! %s \n", optarg);
+ usage(argv[0], c);
break;
case 'h':
usage(argv[0], c);
break;
- default:
- /* fall through */
- break;
}
}