[WTF] holdLock should be marked WARN_UNUSED_RETURN
authorrmorisset@apple.com <rmorisset@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 16 Apr 2019 19:46:27 +0000 (19:46 +0000)
committerrmorisset@apple.com <rmorisset@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 16 Apr 2019 19:46:27 +0000 (19:46 +0000)
commiteecc3042b1e5c90269d2186a788b71db68f58736
tree4f405e601ce6fa82a2451a0ebb8a2aae64b03d28
parent2f3456068c8c38dc44cb228976c105f5e779afa9
[WTF] holdLock should be marked WARN_UNUSED_RETURN
https://bugs.webkit.org/show_bug.cgi?id=196922

Reviewed by Keith Miller.

Source/JavaScriptCore:

There was one case where holdLock was used and the result ignored.
From a comment that was deleted in https://bugs.webkit.org/attachment.cgi?id=328438&action=prettypatch, I believe that it is on purpose.
So I brought back a variant of the comment, and made the ignoring of the return explicit.

* heap/BlockDirectory.cpp:
(JSC::BlockDirectory::isPagedOut):

Source/WTF:

* wtf/Locker.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@244352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/heap/BlockDirectory.cpp
Source/WTF/ChangeLog
Source/WTF/wtf/Locker.h