diff options
Diffstat (limited to 'WebKitTools/Scripts/webkitpy/style')
-rw-r--r-- | WebKitTools/Scripts/webkitpy/style/checker.py | 1 | ||||
-rw-r--r-- | WebKitTools/Scripts/webkitpy/style/checkers/cpp.py | 8 | ||||
-rw-r--r-- | WebKitTools/Scripts/webkitpy/style/checkers/cpp_unittest.py | 15 |
3 files changed, 22 insertions, 2 deletions
diff --git a/WebKitTools/Scripts/webkitpy/style/checker.py b/WebKitTools/Scripts/webkitpy/style/checker.py index 8fc86c3..5d75a1b 100644 --- a/WebKitTools/Scripts/webkitpy/style/checker.py +++ b/WebKitTools/Scripts/webkitpy/style/checker.py @@ -210,6 +210,7 @@ _SKIPPED_FILES_WITH_WARNING = [ "WebKit/gtk/tests/", "WebKit/qt/Api/", "WebKit/qt/tests/", + "WebKit/qt/examples/", ] diff --git a/WebKitTools/Scripts/webkitpy/style/checkers/cpp.py b/WebKitTools/Scripts/webkitpy/style/checkers/cpp.py index 3e787d6..a77bff0 100644 --- a/WebKitTools/Scripts/webkitpy/style/checkers/cpp.py +++ b/WebKitTools/Scripts/webkitpy/style/checkers/cpp.py @@ -1868,8 +1868,12 @@ def check_for_null(file_extension, clean_lines, line_number, error): line = clean_lines.elided[line_number] - # Don't warn about NULL usage in g_object_{get,set}(). See Bug 32858 - if search(r'\bg_object_[sg]et\b', line): + # Don't warn about NULL usage in g_*(). See Bug 32858 and 39372. + if search(r'\bg(_[a-z]+)+\b', line): + return + + # Don't warn about NULL usage in gst_*_many(). See Bug 39740 + if search(r'\bgst_\w+_many\b', line): return # Don't warn about NULL usage in g_str{join,concat}(). See Bug 34834 diff --git a/WebKitTools/Scripts/webkitpy/style/checkers/cpp_unittest.py b/WebKitTools/Scripts/webkitpy/style/checkers/cpp_unittest.py index 5a5aabd..d7cb876 100644 --- a/WebKitTools/Scripts/webkitpy/style/checkers/cpp_unittest.py +++ b/WebKitTools/Scripts/webkitpy/style/checkers/cpp_unittest.py @@ -3437,6 +3437,21 @@ class WebKitStyleTest(CppStyleTestBase): 'g_object_set(foo, "prop", bar, NULL);', '') self.assert_lint( + 'g_build_filename(foo, bar, NULL);', + '') + self.assert_lint( + 'gst_bin_add_many(foo, bar, boo, NULL);', + '') + self.assert_lint( + 'gst_bin_remove_many(foo, bar, boo, NULL);', + '') + self.assert_lint( + 'gst_element_link_many(foo, bar, boo, NULL);', + '') + self.assert_lint( + 'gst_element_unlink_many(foo, bar, boo, NULL);', + '') + self.assert_lint( 'gchar* result = g_strconcat("part1", "part2", "part3", NULL);', '') self.assert_lint( |