Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug in 'ListenerImpl' #2137

Closed
qclzdh opened this issue Dec 19, 2023 · 1 comment · Fixed by #2139
Closed

Bug in 'ListenerImpl' #2137

qclzdh opened this issue Dec 19, 2023 · 1 comment · Fixed by #2139
Assignees

Comments

@qclzdh
Copy link

qclzdh commented Dec 19, 2023

Required information

Operating system:
E.g. Ubuntu 20.04 LTS

Compiler version:
E.g. GCC 9.4.0

Eclipse iceoryx version:
master

Observed result or behaviour:
process crashed

Expected result or behaviour:
process run normally

Conditions where it occurred / Performed steps:
change the examples as following, and then run it

diff --git a/iceoryx_examples/callbacks/ice_callbacks_subscriber.cpp b/iceoryx_examples/callbacks/ice_callbacks_subscriber.cpp
index e25cc5856..871a93432 100644
--- a/iceoryx_examples/callbacks/ice_callbacks_subscriber.cpp
+++ b/iceoryx_examples/callbacks/ice_callbacks_subscriber.cpp
@@ -76,10 +76,11 @@ int main()
 {
     iox::runtime::PoshRuntime::initRuntime(APP_NAME);
 
+std::cout << "test ListenerImpl " << std::endl;
     // the listener starts a background thread and the callbacks of the attached events
     // will be called in this background thread when they are triggered
     //! [create listener]
-    iox::popo::Listener listener;
+    iox::popo::ListenerImpl<10> listener;
     //! [create listener]
 
     //! [create heartbeat and subscribers]

@qclzdh qclzdh changed the title bug in bug in ListenerImpl Dec 19, 2023
@elBoberido
Copy link
Member

Indded, there is an issue in the ListenerImpl when used directly but it is not meant to use directly. Only the Listener itself is public API. The ListenerImpl was created to try to fix an issue with the C binding which in the end did not work and should have been reverted.

Why exactly do you want to use the ListenerImpl instead of the Listener?

@elBoberido elBoberido changed the title bug in ListenerImpl Bug in 'ListenerImpl' Dec 20, 2023
elBoberido added a commit to elBoberido/iceoryx that referenced this issue Dec 20, 2023
elBoberido added a commit to elBoberido/iceoryx that referenced this issue Dec 20, 2023
elBoberido added a commit that referenced this issue Dec 20, 2023
…back-to-listener

iox-#2137 Merge 'ListenerImpl' back to 'Listener'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants