From 1593ef2626842bddf61127b55e1450d40448e252 Mon Sep 17 00:00:00 2001 From: George Burgess IV Date: Wed, 25 Jan 2017 13:51:53 -0800 Subject: Add mode to open call with O_CREAT This change was already applied internally. For us to submit FORTIFY, we need to push it out here. Otherwise, we get compile-time errors about this. Bug: 32073964 Test: Builds with FORTIFY. Change-Id: Ib500aca933468c06f7ceb796a9bb6a16c118e366 Merged-In: I63eb3d5499ae7e9ff9a77393763e39b747fd4611 --- cmds/atrace/atrace.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmds/atrace/atrace.cpp b/cmds/atrace/atrace.cpp index ee2b2758fc..64f7b820fd 100644 --- a/cmds/atrace/atrace.cpp +++ b/cmds/atrace/atrace.cpp @@ -1243,7 +1243,7 @@ int main(int argc, char **argv) fflush(stdout); int outFd = STDOUT_FILENO; if (g_outputFile) { - outFd = open(g_outputFile, O_WRONLY | O_CREAT); + outFd = open(g_outputFile, O_WRONLY | O_CREAT, 0644); } if (outFd == -1) { printf("Failed to open '%s', err=%d", g_outputFile, errno); -- cgit v1.2.3-59-g8ed1b