What is the difference between a direct and indirect leak?

The LSan wiki design document states:

Another useful feature is being able to distinguish between directly leaked
blocks (not reachable from anywhere) and indirectly leaked blocks (reachable
from other leaked blocks).

Stated another way, indirect leaks are a result of direct leaks. Fixing direct leaks should make the indirect leaks become either fixed or direct leaks themselves (depending on whether their memory management is implemented correctly or not, respectively).

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)