[gpt] Fix edit_cros args parsing
Test: Run gpt edit_cros on pixelbook
Change-Id: I599c88df86f5a0b11dfbf2793b7cea3320da4402
diff --git a/zircon/system/uapp/gpt/gpt.cpp b/zircon/system/uapp/gpt/gpt.cpp
index 6c89be9..710fae5 100644
--- a/zircon/system/uapp/gpt/gpt.cpp
+++ b/zircon/system/uapp/gpt/gpt.cpp
@@ -491,7 +491,7 @@
fprintf(stderr, "tries must be in the range [0, 16)\n");
return Usage(ZX_ERR_INVALID_ARGS);
}
- *(out_args->tries) = val;
+ out_args->tries = val;
break;
}
case 'P': {
@@ -503,14 +503,14 @@
fprintf(stderr, "priority must be in the range [0, 16)\n");
return Usage(ZX_ERR_INVALID_ARGS);
}
- *(out_args->priority) = val;
+ out_args->priority = val;
break;
}
case 'S': {
if (!strncmp(optarg, "0", 2)) {
- *(out_args->successful) = 0;
+ out_args->successful = 0;
} else if (!strncmp(optarg, "1", 2)) {
- *(out_args->successful) = 1;
+ out_args->successful = 1;
} else {
fprintf(stderr, "successful must be 0 or 1\n");
return Usage(ZX_ERR_INVALID_ARGS);