You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Brad Hoekstra (JIRA)" <ji...@apache.org> on 2013/01/31 14:59:13 UTC
[jira] [Updated] (QPID-4556) QueueOptions::setSizePolicy() can
cause exception
[ https://issues.apache.org/jira/browse/QPID-4556?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Brad Hoekstra updated QPID-4556:
--------------------------------
Attachment: QPID-4556.diff
Attaching diff.
> QueueOptions::setSizePolicy() can cause exception
> -------------------------------------------------
>
> Key: QPID-4556
> URL: https://issues.apache.org/jira/browse/QPID-4556
> Project: Qpid
> Issue Type: Bug
> Components: C++ Broker, C++ Client
> Affects Versions: 0.20
> Environment: Linux x86_64
> Reporter: Brad Hoekstra
> Attachments: QPID-4556.diff
>
>
> Calling QueueOptions::setSizePolicy() with maxSize > 2GB causes an exception in the C++ broken, which then generates an exception in the C++ client library.
> This appears to be because the value is set as an int32 in the FieldTable. The fix appears to be fairly simple:
> Index: 0.20/cpp/src/qpid/client/QueueOptions.cpp
> ===================================================================
> --- 0.20/cpp/src/qpid/client/QueueOptions.cpp (revision 27169)
> +++ 0.20/cpp/src/qpid/client/QueueOptions.cpp (revision 27170)
> @@ -49,8 +49,8 @@
>
> void QueueOptions::setSizePolicy(QueueSizePolicy sp, uint64_t maxSize, uint32_t maxCount)
> {
> - if (maxCount) setInt(strMaxCountKey, maxCount);
> - if (maxSize) setInt(strMaxSizeKey, maxSize);
> + if (maxCount) setUInt64(strMaxCountKey, maxCount);
> + if (maxSize) setUInt64(strMaxSizeKey, maxSize);
> if (maxSize || maxCount){
> switch (sp)
> {
--
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