From fb1e4465f14a4fcf8376a6c249bcdf86af915e69 Mon Sep 17 00:00:00 2001 From: Akira Hatanaka Date: Tue, 6 Nov 2018 06:26:17 +0000 Subject: os_log: Add a new privacy annotation "sensitive". MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is a stricter privacy annotation than "private", which will be used for data that shouldn’t be logged to disk. For backward compatibility, the "private" bit is set too. rdar://problem/36755912 llvm-svn: 346210 --- clang/lib/AST/OSLog.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'clang/lib/AST/OSLog.cpp') diff --git a/clang/lib/AST/OSLog.cpp b/clang/lib/AST/OSLog.cpp index 9124fd58a05..d70aa605182 100644 --- a/clang/lib/AST/OSLog.cpp +++ b/clang/lib/AST/OSLog.cpp @@ -120,7 +120,9 @@ public: ArgsData.back().FieldWidth = Args[FS.getFieldWidth().getArgIndex()]; } - if (FS.isPrivate()) + if (FS.isSensitive()) + ArgsData.back().Flags |= OSLogBufferItem::IsSensitive; + else if (FS.isPrivate()) ArgsData.back().Flags |= OSLogBufferItem::IsPrivate; else if (FS.isPublic()) ArgsData.back().Flags |= OSLogBufferItem::IsPublic; -- cgit v1.2.3