You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@etch.apache.org by "Aaron Frueh (JIRA)" <ji...@apache.org> on 2013/11/28 15:44:37 UTC
[jira] [Updated] (ETCH-275) ValueFactory SRuntimes Mutex not
unlocked
[ https://issues.apache.org/jira/browse/ETCH-275?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Aaron Frueh updated ETCH-275:
-----------------------------
Attachment: 0001-ETCH-275-Fixed-SRuntimes-Mutex-unlock-in-Code-genera.patch
Please look at the following patch!
> ValueFactory SRuntimes Mutex not unlocked
> -----------------------------------------
>
> Key: ETCH-275
> URL: https://issues.apache.org/jira/browse/ETCH-275
> Project: Etch
> Issue Type: Bug
> Components: binding-cpp
> Affects Versions: 1.3.0
> Environment: All
> Reporter: Aaron Frueh
> Attachments: 0001-ETCH-275-Fixed-SRuntimes-Mutex-unlock-in-Code-genera.patch
>
> Original Estimate: 0.5h
> Remaining Estimate: 0.5h
>
> (Code Generation)
> The Static SRuntimes Mutex is not unlocked on every Error-Case and resolves to deadlocks.
> See following example:
> status_t ValueFactoryRemoting::InitValueFactory(EtchRuntime* runtime)
> {
> status_t status;
> SRuntimesMutex.lock();
> if (SRuntimes.find(runtime->getId()) != SRuntimes.end()) {
> //runtime is already in list
> return ETCH_OK; <=== Missing unlock
> }
> status = SRuntimes.push_back(runtime->getId());
> runtime->registerListener(&SRemotingRuntimeListener);
> if (status != ETCH_OK) {
> return status; // <=== Missing unlock
> }
> if (SRuntimes.size() > 1) {
> //Valuefactory is already initialized
> SRuntimesMutex.unlock();
> return ETCH_OK;
> }
> SRuntimesMutex.unlock();
--
This message was sent by Atlassian JIRA
(v6.1#6144)