| commit | cef5fbb2e93282414ac9f4e278fcf8f70b27b7c2 | [log] [tgz] |
|---|---|---|
| author | Chih-hung Hsieh <chh@google.com> | Thu Dec 22 00:06:15 2022 +0000 |
| committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | Thu Dec 22 00:06:15 2022 +0000 |
| tree | 382b88618145fca74fc90170e5b6bc6d76e798ea | |
| parent | 54c5f0d0dfe4e5e09cb67eace21eb676e4935a63 [diff] | |
| parent | 442e08ffa798dea9bb6b0e48cf364d67a2ca3d79 [diff] |
Merge "Fix uninitialized value warnings."
diff --git a/tools/atree/fs.cpp b/tools/atree/fs.cpp index 6cd080e..d004e97 100644 --- a/tools/atree/fs.cpp +++ b/tools/atree/fs.cpp
@@ -177,7 +177,7 @@ } else { // Split the arguments if more than 1 char* cmd = strdup(strip_cmd); - const char** args = (const char**) malloc(sizeof(const char*) * (num_args + 2)); + const char** args = (const char**) calloc((num_args + 2), sizeof(const char*)); const char** curr = args; char* s = cmd;