[PATCH] Sanitize printf functions
Alexander Potapenko
glider at google.com
Tue Jan 21 02:18:52 PST 2014
A couple of nits.
================
Comment at: lib/sanitizer_common/tests/sanitizer_scanf_interceptor_test.cc:43
@@ +42,3 @@
+static const unsigned D = sizeof(double); // NOLINT
+static const unsigned LD = sizeof(long double); // NOLINT
+static const unsigned F = sizeof(float); // NOLINT
----------------
At least two spaces between the code and the comment, please (you'll need to reformat the rest of declarations)
================
Comment at: lib/sanitizer_common/tests/sanitizer_scanf_interceptor_test.cc:37
@@ -26,3 +36,3 @@
-static const char scanf_buf[] = "Test string.";
-static size_t scanf_buf_size = sizeof(scanf_buf);
+static const unsigned I = sizeof(int); // NOLINT
+static const unsigned L = sizeof(long); // NOLINT
----------------
Can you please add a comment above describing why NOLINT is necessary here?
http://llvm-reviews.chandlerc.com/D2480
More information about the llvm-commits
mailing list