qpid-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robbie Gemmell (JIRA)" <j...@apache.org>
Subject [jira] [Closed] (QPID-2405) SASL<->Ruby binding can cause seg_faults
Date Sat, 13 Aug 2011 18:14:27 GMT

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

Robbie Gemmell closed QPID-2405.
--------------------------------

       Resolution: Won't Fix
    Fix Version/s:     (was: 0.5)

Closing out issue, this relates to the old ruby client which was removed from the repo, and
not the newer ruby bindings for the C++ messaging API.

> SASL<->Ruby binding can cause seg_faults
> ----------------------------------------
>
>                 Key: QPID-2405
>                 URL: https://issues.apache.org/jira/browse/QPID-2405
>             Project: Qpid
>          Issue Type: Bug
>          Components: Ruby Client
>    Affects Versions: 0.5
>         Environment: Ubuntu, ruby 1.8.7, qpid 0.5
>            Reporter: Sam Hendley
>            Assignee: Ted Ross
>              Labels: sasl, segmenation_fault
>         Attachments: sasl.patch
>
>
> There is an issue with the sasl bindings where it returns a raw ruby VALUE type for the
sasl context. This works _UNTIL_ the ruby runtime tries to access that variable which then
causes a segfault. 
> This is easy to see if you try to inspect the variable at all (like print it or ask for
its class or methods). In my application, for reasons I haven't determined yet, just having
this variable on the heap meant that when an exception occurred trying to print the exceptions
message caused a seg fault. 
> In any case, passing back raw VALUEs to ruby code is a Bad Idea and goes against the
spec. There is a simple macro and fix for this which wraps the returned value in a ruby object.
This fixes the issue I was having and means the deleting of the object is done automatically
(instead of having a manual free function).
> I have a patch with the simple, low impact fix, really it would be better to the extension
so the sasl client is repersented as a real ruby object but that would require atleast some
client code changes.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


Mime
View raw message