am 3d561748: am ec035950: Merge "Clean up -p handling slightly."
* commit '3d5617487c07f1fcbdf23755e0ca01559e3c5f3b':
Clean up -p handling slightly.
diff --git a/adb/commandline.cpp b/adb/commandline.cpp
index 185d566..e0e608e 100644
--- a/adb/commandline.cpp
+++ b/adb/commandline.cpp
@@ -998,7 +998,7 @@
/* this is a special flag used only when the ADB client launches the ADB Server */
is_daemon = 1;
} else if (!strncmp(argv[0], "-p", 2)) {
- const char *product = NULL;
+ const char* product = nullptr;
if (argv[0][2] == '\0') {
if (argc < 2) return usage();
product = argv[1];
@@ -1007,7 +1007,7 @@
} else {
product = argv[0] + 2;
}
- if (product) gProductOutPath = find_product_out_path(product);
+ gProductOutPath = find_product_out_path(product);
if (gProductOutPath.empty()) {
fprintf(stderr, "adb: could not resolve \"-p %s\"\n", product);
return usage();