summaryrefslogtreecommitdiffstats
path: root/www/analyzer
diff options
context:
space:
mode:
Diffstat (limited to 'www/analyzer')
-rw-r--r--www/analyzer/alpha_checks.html24
1 files changed, 24 insertions, 0 deletions
diff --git a/www/analyzer/alpha_checks.html b/www/analyzer/alpha_checks.html
index 0312d16ace..ce9392b996 100644
--- a/www/analyzer/alpha_checks.html
+++ b/www/analyzer/alpha_checks.html
@@ -910,6 +910,30 @@ void test(char *y) {
}
</pre></div></div></td></tr>
+
+<tr><td><div class="namedescr expandable"><span class="name">
+alpha.unix.cstring.BlockInCriticalSection</span><span class="lang">
+(C)</span><div class="descr">
+Check for calls to blocking functions inside a critical section; applies
+to:<div class=functions>
+lock, unlock<br>
+sleep<br>
+getc<br>
+fgets<br>
+read<br>
+recv<br>
+pthread_mutex_lock, pthread_mutex_trylock, pthread_mutex_unlock<br>
+mtx_lock, mtx_timedlock, mtx_trylock, mtx_unlock<br>
+</div></div></div></td>
+<td><div class="exampleContainer expandable">
+<div class="example"><pre>
+void testBlockInCriticalSection() {
+ std::mutex m;
+ m.lock();
+ sleep(3); // warn
+ m.unlock();
+}
+</pre></div></div></td></tr>
</tbody></table>
</div> <!-- page -->