[
https://issues.apache.org/jira/browse/TS-3315?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14289020#comment-14289020
]
taorui commented on TS-3315:
----------------------------
it`s great if you document it.
if the caller has interest of the result of remove (cont != NULL), then the
current thread must hold the lock of cont->mutex
if not (cont == NULL), the try should lock.
> Assert after try lock
> ---------------------
>
> Key: TS-3315
> URL: https://issues.apache.org/jira/browse/TS-3315
> Project: Traffic Server
> Issue Type: Bug
> Components: Cache
> Reporter: Phil Sorber
>
> In iocore/cache/Cache.cc there is the following:
> {code}
> CACHE_TRY_LOCK(lock, cont->mutex, this_ethread());
> ink_assert(lock.is_locked());
> {code}
> Does it really make sense to try and assert when a try can fail?
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)