qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexey Sviridov (JIRA)" <j...@apache.org>
Subject [jira] [Created] (QPID-4425) Possible incorrect error reporting "Error locking blob area for persistable item"
Date Wed, 07 Nov 2012 03:58:12 GMT
Alexey Sviridov created QPID-4425:
-------------------------------------

             Summary: Possible incorrect error reporting "Error locking blob area for persistable
item"
                 Key: QPID-4425
                 URL: https://issues.apache.org/jira/browse/QPID-4425
             Project: Qpid
          Issue Type: Improvement
          Components: C++ Broker
    Affects Versions: 0.18
         Environment: Windows
            Reporter: Alexey Sviridov
            Priority: Trivial


In mssql_store module class BlobEncoder has incorrect error reporting.
In code bellow
{code:title=BlobEncoder.cpp}
    blob = SafeArrayCreate(VT_UI1, 1, bound);
    if (S_OK != SafeArrayLock(blob)) {
        SafeArrayDestroy(blob);
        blob = 0;
        throw qpid::Exception("Error locking blob area for persistable item");
    }
{code} 

Exception "Error locking blob area for persistable item" hides possible error in SafeArrayCreate
(which is more likely to be happen, cause SafeArrayCreate can fail on out of memory)
In module BlobEncoder.cpp three similar methods. (BTW may be it's need some refactoring to
follow DRY principe& :) )

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


Mime
View raw message