You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Andrei Gheorghe (JIRA)" <ji...@apache.org> on 2013/06/19 16:05:19 UTC

[jira] [Updated] (AMQCPP-494) Commiting a session with a deleted consumer causes access violation

     [ https://issues.apache.org/jira/browse/AMQCPP-494?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrei Gheorghe updated AMQCPP-494:
-----------------------------------

    Description: 
I'm not sure if this is a bug or if I'm using the library wrong.
The following program will cause an access violation error when trying to commit the session.


  was:
I'm not sure if this is a bug or if I'm using the library wrong.
The following program will cause an access violation error when trying to commit the session.

#include <activemq/core/ActiveMQConnectionFactory.h>
#include <activemq/commands/ActiveMQQueue.h>
#include <activemq/library/ActiveMQCPP.h>

int main()
{
	activemq::library::ActiveMQCPP::initializeLibrary();

	activemq::core::ActiveMQConnectionFactory factory("tcp://localhost:61616");
	activemq::commands::ActiveMQQueue queue("testqueue");

	cms::Connection* connection = factory.createConnection();
	connection->start();
	cms::Session* session = connection->createSession(cms::Session::SESSION_TRANSACTED);
	cms::MessageConsumer* consumer = session->createConsumer(&queue);

	consumer->receive();
	delete consumer;
	session->commit();

	activemq::library::ActiveMQCPP::shutdownLibrary();
}

    
> Commiting a session with a deleted consumer causes access violation
> -------------------------------------------------------------------
>
>                 Key: AMQCPP-494
>                 URL: https://issues.apache.org/jira/browse/AMQCPP-494
>             Project: ActiveMQ C++ Client
>          Issue Type: Bug
>    Affects Versions: 3.7.0
>            Reporter: Andrei Gheorghe
>            Assignee: Timothy Bish
>            Priority: Minor
>         Attachments: test.cpp
>
>
> I'm not sure if this is a bug or if I'm using the library wrong.
> The following program will cause an access violation error when trying to commit the session.

--
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